Applescript to change contact names to Title Case

That pretty well some it up.  I've looked and looked and it seems this is not an easy thing to do!  I guess the Proper() function from Excel doesn't exist in applescript?
Hope someone knows how to do this. MANY THANKS

Actually, you're using 10.7, so you can leverage cocoa.  Create an applescript-cocoa application in the Applescript Editor (from the New from Template submenu), and play with the following code:
display alert properCase("test string")
on properCase(t)
          set cocoaString to current application's NSString's stringWithString_(t)
          return (cocoaString's capitalizedString()) as text
end properCase

Similar Messages

  • How to convert a file name to title case

    hi,
      I have document library where name is displayed for the file that is uploaded. How do I convert the name to a calculated column =PROPER([name])? I've tried creating a new column, which is a calculated field =PROPER([name]) but it doesn't recognized
    the field. There is the title column which I can do a =PROPER([title]), but the title field isn't necessarily the same as the file name. Ideally, I want to convert to title case for any file uploaded. so the Name column is in the PROPER case. Thanks.

    "Title" is a field on the entity in the database. "Name" is what uniquely identifies the SPFile underlying the document.
    So you can think of Title as pretty arbitrary; you can change it just like you would change any other property (description, etc.) but if you change the Name, it is akin to moving the file. Names must be unique in folders/webs.

  • Bug in Changing Contact Names

    Recently as I've changed my contacts' names (from the conversation window), Skype has simply corrected them to 'sex'. That's it. 'sex'. However, when I navigate away from the chat and come back to it, the changed name is now reflected.
    This has shown up for all contacts I've tried to change! It's amusing, but nsfw. I hope the bug can be resolved soon!

    I always find editing contacts using Ovi suite on the desk top works better than on the phone, then just sync contacts !
    If I have helped at all, a click on the White Star is always appreciated :
    you can also help others by marking 'accept as solution' 

  • IPhone freezes when I change contact name

    Hello guys
    So, my girlfriend has an iPhone 5S and when I/She try to change the name of any contact the smartphone freezes and I have to power it off.
    I tried updating it to the lastest iOS version but it didn't solve the problem.
    What should I do?

    Hi Jersep,
    Since this is an issue that has carried over from one device to a new device, it seems like the source of this issue may be from your data in your backup. Try using the following article to restore your software and test the device as a new phone, free from your backup data, to see if this affects the issue:
    iOS: How to back up your data and set up your device as a new device
    http://support.apple.com/kb/HT4137
    Thanks for coming to the Apple Support Communities!
    Regards,
    Braden

  • Trying to use regular expressions to convert names to Title Case

    I'm trying to change names to their proper case for most common names in North America (esp. the U.S.).
    Some examples are in the comments of the included code below.
    My problem is that *retName = retName.replaceAll("( [^ ])([^ ]+)", "$1".toUpperCase() + "$2");* does not work as I expect. It seems that the toUpperCase method call does not actually do anything to the identified group.
    Everything else works as I expect.
    I'm hoping that I do not have to iterate through each character of the string, upshifting the characters that follow spaces.
    Any help from you RegEx experts will be appreciated.
    {code}
    * Converts names in some random case into proper Name Case. This method does not have the
    * extra processing that would be necessary to convert street addresses.
    * This method does not add or remove punctuation.
    * Examples:
    * DAN MARINO --> Dan Marino
    * old macdonald --> Old Macdonald <-- Can't capitalize the 'D" because of Ernst Mach
    * ROY BLOUNT, JR. --> Roy Blount, Jr.
    * CAROL mosely-BrAuN --> Carol Mosely-Braun
    * Tom Jones --> Tom Jones
    * ST.LOUIS --> St. Louis
    * ST.LOUIS, MO --> St. Louis, Mo <-- Avoid City Names plus State Codes
    * This is a work in progress that will need to be updated as new exceptions are found.
    public static String toNameCase(String name) {
    * Basic plan:
    * 1. Strategically create double spaces in front of characters to be capitalized
    * 2. Capitalize characters with preceding spaces
    * 3. Remove double spaces.
    // Make the string all lower case
    String retName = name.trim().toLowerCase();
    // Collapse strings of spaces to single spaces
    retName = retName.replaceAll("[ ]+", " ");
    // "mc" names
    retName = retName.replaceAll("( mc)", " $1");
    // Ensure there is one space after periods and commas
    retName = retName.replaceAll("(\\.|,)([^ ])", "$1 $2");
    // Add 2 spaces after periods, commas, hyphens and apostrophes
    retName = retName.replaceAll("(\\.|,|-|')", "$1 ");
    // Add a double space to the front of the string
    retName = " " + retName;
    // Upshift each character that is preceded by a space
    // For some reason this doesn't work
    retName = retName.replaceAll("( [^ ])([^ ]+)", "$1".toUpperCase() + "$2");
    // Remove double spaces
    retName = retName.replaceAll(" ", "");
    return retName;
    Edited by: FuzzyBunnyFeet on Jan 17, 2011 10:56 AM
    Edited by: FuzzyBunnyFeet on Jan 17, 2011 10:57 AM                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

    Hopefully someone will still be able to provide a RegEx solution, but until that time here is a working method.
    Also, if people have suggestions of other rules for letter capitalization in names, I am interested in those too.
    * Converts names in some random case into proper Name Case.  This method does not have the
    * extra processing that would be necessary to convert street addresses.
    * This method does not add or remove punctuation.
    * Examples:
    * CAROL mosely-BrAuN --> Carol Mosely-Braun
    * carol o'connor --> Carol O'Connor
    * DAN MARINO --> Dan Marino
    * eD mCmAHON --> Ed McMahon
    * joe amcode --> Joe Amcode         <-- Embedded "mc"
    * mr.t --> Mr. T                    <-- Inserted space
    * OLD MACDONALD --> Old Macdonald   <-- Can't capitalize the 'D" because of Ernst Mach
    * old mac donald --> Old Mac Donald
    * ROY BLOUNT,JR. --> Roy Blount, Jr.
    * ST.LOUIS --> St. Louis
    * ST.LOUIS,MO --> St. Louis, Mo     <-- Avoid City Names plus State Codes
    * Tom Jones --> Tom Jones
    * This is a work in progress that will need to be updated as new exceptions are found.
    public static String toNameCase(String name) {
         * Basic plan:
         * 1.  Strategically create double spaces in front of characters to be capitalized
         * 2.  Capitalize characters with preceding spaces
         * 3.  Remove double spaces.
        // Make the string all lower case
        String workStr = name.trim().toLowerCase();
        // Collapse strings of spaces to single spaces
        workStr = workStr.replaceAll("[ ]+", " ");
        // "mc" names
        workStr = workStr.replaceAll("( mc)", "  $1  ");
        // Ensure there is one space after periods and commas
        workStr = workStr.replaceAll("(\\.|,)([^ ])", "$1 $2");
        // Add 2 spaces after periods, commas, hyphens and apostrophes
        workStr = workStr.replaceAll("(\\.|,|-|')", "$1  ");
        // Add a double space to the front of the string
        workStr = "  " + workStr;
        // Upshift each character that is preceded by a space and remove double spaces
        // Can't upshift using regular expressions and String methods
        // workStr = workStr.replaceAll("( [^ ])([^ ]+)", "$1"toUpperCase() + "$2");
        StringBuilder titleCase = new StringBuilder();
        for (int i = 0; i < workStr.length(); i++) {
            if (workStr.charAt(i) == ' ') {
                if (workStr.charAt(i+1) == ' ') {
                    i += 2;
                while (i < workStr.length() && workStr.charAt(i) == ' ') {
                    titleCase.append(workStr.charAt(i++));
                if (i < workStr.length()) {
                    titleCase.append(workStr.substring(i, i+1).toUpperCase());
            } else {
                titleCase.append(workStr.charAt(i));
        return titleCase.toString();
    {code}                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

  • Change page name and title

    Hello,
    I am using oracle apex 4.1. I created two pages with a tab set. I am able to change the page name/title through edit page properties. But it is not reflecting when I run the application/page. If I delete the page and create a new page with new page name, i am able to see it.
    can anybody suggest me how to change the page name/title?
    Thank you

    manyam16 wrote:
    I am using oracle.apex.com and using the workspace created for me. How can I create an application and show it to you as you mentioned in your reply, that would be great.For questions on layout, HTML, CSS and JavaScript it's usually sufficient to simply make the relevant page(s) of an application available, either by creating an app requiring no authentication, or setting the Authentication attribute on a specific page to Page is Public. Post a link to the page with your question.
    To investigate more complex problems, in areas like security, validation and processing, or relating to database objects, we need access to the app. You should create a guest developer account in your apex.oracle.com workspace. Unlock it and post workspace, username, and (temporary) password login credentials for it when the need arises. Change the password and lock the account again when the problem is solved.

  • Applescript to change Folder names

    Can someone suggest an Applescript that would convert the names within a given Finder folder?
    For example,
    I have a folder full of photos that were relabeled and not recognized by the iPad when using the Camera Connection Kit. They need to be converted to 8 character names (no special characters). For example, I wish to change:
    20140923 (12).JPG    to     14092312.JPG
    In general, change 201409wx (yz)   to    1409wxyz where wxy and z are unique numbers.

    Use the following:
    tell application "Finder"
    repeat with this_file in (get files of (choose folder))
    set the_name to name of this_file
    set name of this_file to {get items 3 thru 8 of the_name, get items 11 thru 12 of the_name, get items 14 thru -1 of the_name} as string
    end repeat
    end tell
    (114533)

  • Changed contact name after 10.2 upgrade

    After I upgraded my Z10 to v10.2.0.424 my contact entry name changed from my name (format: first last name) to my birthday (format: YYYY-MM-DD 00:00:00)?!?!  I went to edit my contact entry and I can chenge everyhing but the name.  Any ideas on how to fix this?

    it appears I didn't have the user's BBM PIN entered.  when i entered it into their contact, saved.  REOPENED the contact, their first and last name showed up.
    Weird but true.

  • IPhone changes contact name

    I have an iPhone 3G running OS 3.0
    I have a contact stored as a first name only, Mobile and email.
    When ever i receive an email from him, The iphone automatically changes his stored name to the one written in his email name.
    What is the reason please ? and how can solve it please ?
    Thanks

    I have the same issue with my 3G. What I found out is that - apparently - the Address Book was made for people with First AND Last names, so if you don't use one of them when you receive an e-mail from this person it will automatically changes the contact field, using that one registered with the email. The only solution for me until now was to mark those contacts that I use only the first or the last name as COMPANY. That seems to solve the problem, but I'm still hoping to find a more effective way out.

  • Can't change contact name of recent numbers I call...

    I recently called a number and I would like to add that number to my contact's with the appropriate name.  Visiting the profile and even typing the number in again on the keypad doesn't seem to give  any option to save this contact with an appropriate name.  I can't believe i'm even here typing this.  The small 3 dot's lower right hand corner only give the option to block or remove contact. 
    I thought this was 2014.

    Yes absolutely amateur and unbelievably inconsiderate and above all DUMB to omit this function. I now have a long list of numbers in recently called and a big hassle if I want to figure out who is who. I thought it was either me being thick, or something temporary glitch. But obviously no one at Skype CARES, is this true? Do I pay for this service???

  • GRC CUP - How to change SNC Name to lower case during user creation.

    Hi All,
    We are using GRC 5.3. CUP automatically creates user in R3 but SNC p:username'@'DOMAIN.COM is in upper case.
    1. During automated user creation.
    2. How change default DOMAIN.COM to lower case "domain.com"
    Currently we have to manually change is via SU01 after user has been created.
    Thank you
    Regards,
    Jacky

    Sorry please ignore this thread. I got the wrong details. Post cancelled

  • Is there a API to  change user name in portal security realm

    Our portal application requires the functionality to change user login name which
    maps to the user_name in USER_SECURITY table.
    The com.bea.p13n.usermgmt.UserManager does not offer a API to change user name, so
    my code changed it directly in the USER_SECURITY table by JDBC.
    My concern is : other tables in portal db may also has the user_name which are not
    be changed correspondingly, this may cause problem which I don't see now (e.g. Entity
    table has user_name also).
    Question is: is there a safe way to change user_name consistantly in portal database?
    like a API or do I have to do it myself. If it is the second case, what other tables
    I need to change.
    Thank you for all your input.
    Ellen

    I also have a similar ?, is changing user name a normal case scenario or a big problem in portal
    Please reply

  • How can i change a contact name pronunciation on siri

    how can i change a contact name pronunciation on siri

    under contacts, there's a field for "phonetic first/last name." Just spell it how it sounds and Siri will get it.
    If you don't find the field, go into edit mode and choose "add field".

  • How to prevent middle names and titles from appearing in contacts

    My iPhone is syncrhonised with MS Outlook, and I've used Outlook as my system of record for contacts for many years. I have hundreds of contacts in Outlook, many of which contain middle names and titles.
    The problem is that the iPhone displays every contact as Title FirstName MiddleName Surname Suffix. For many of my contacts, particularly when viewed in the Favourites list, I can't even see the contact's surname because the contact's title, first name and middle name(s) take up so much of the row.
    How can I stop my iPhone from displaying titles and middle names? Is there a setting somewhere in iTunes that will prevent these fields from being transferred to the iPhone?

    @NFH
    I am also experiencing this problem, but I think it started with one of the later iOS 3.x releases or possible iOS4. All of my contacts display their job title (eg. "Senior Vice President of Worldwide Sales & Operations") which given the screen real estate means that NONE of the actual Contact name is visible.
    This is only happening on my iPhone 3GS (iOS 4.0.2) and does NOT happen on my Mac, my me.com, nor on my iPad (iOS 3.2.2). Which, again leads me to believe this problem was introduced in iOS4.

  • Iphone 4s - how do I change the name in the contacts for the owner of the phone - it is coming up as the other person who uses the laptop - so when ringing or texting anyone 2 names are being used as the caller id on the screen

    Iphone 4s - how do I change the name in the contacts for the owner of the phone - it is coming up as the other person who uses the laptop - so when ringing or texting anyone 2 names are being used as the caller id on the screen

    *Ralph Johns* writes:
    "Your options are:
    Get a trial account form @mac which will work as an iChat name after the 60 days run out but not be a email account that is valid (And is free)"
    Do you mean a trial account from .Mac? (DotMac)
    "Get an AIM Screen name and set it to Display what you want as you set it up.
    The Screen name can be whatever yu want but you can also set it to display something else as well."
    I had thought about this, but it seems other people have already chosen the screen name "pinksharkmark" and virtually every variation of it I can think of. So that isn't an option for me. As for getting it to display something else as well, do you mean that if I were to get an AIM screen name like "CromulentCat" I could somehow log in to iChat under the AIM account "CromulentCat" yet get iChat to represent me to my Buddies as "PinkSharkMark"? Because I have to admit I don't see how that can be done. It appears as if iChat displays to anyone chatting with you precisely the account name you logged in under and nothing else. So if you logged in using a .Mac account, then you are displayed as "[email protected]" while if you logged in under an AIM account, you are displayed as "CromulentCat". But that's it that's all... there is no way to change CromulentCat to PinkSharkMark.
    Thanks very much for taking the time to reply, though.

Maybe you are looking for

  • My Mail Will No Longer Send Out! I Have A Picture Of The Message I Get...

    For some reason, the last couple of days my mail will no longer send out. The e-mails that I want to send just sit in my outbox. I don't know what to do... Here is a picture of the message that I keep getting: Hopefully someone will know what to do b

  • Java concurrent program class not found Exception in oracle apps

    Hi all, I done java concurrent program as per steps given by oracle.I am getting class not exception when i am submitting that concurrent program. My java file is under $JAVA_TOP specified folder.Those path from $JAVA_TOP i set in apps (System Admins

  • Customer/Sales order stock

    Hi, The requirement is, 1.The Scenario is to create a Sales order and block the Stock with batches to the particular Customer/Sales order. How to process this, can 412 E thru MB1B tcode can be used or any other way? any diff if we block with referenc

  • Re-using UCWA app after page reload

    Is it possible to re-use UCWA app/token when navigating on a website instead of authenticating and creating new application after navigating to another page (aka clicking on a links in a menu - not leaving the actual website)? At the moment I have to

  • CLEAR CONSOLE!

    help! i'm programming in java...my program outputs to the command prompt screen. how do i CLEAR a screen so i have a fresh new blank screen....is there some method available to do so?