+ Reply to Thread
Results 1 to 2 of 2

How to parse a name field and separate First, Mid, Last

  1. #1
    Forum Contributor harrywaldron's Avatar
    Join Date
    05-24-2007
    Location
    Roanoke, VA
    MS-Off Ver
    Office Professional 2010 BETA
    Posts
    169

    Question How to parse a name field and separate First, Mid, Last

    Hi - What are some good ways of finding spaces in a complete name field and separating them into individual fields (First Middle Last) ... For example, if we found "old chippy" in A1, we'd like to put "old" in B1 and "chippy" in C1

    This might be compounded by some names having middle initials and others not, but we can clean that up manually. So if we could find the 1st space only that would help a lot without getting too complicated in all the possible combinations out there.

    As always, thanks for any ideas or help on this
    Last edited by harrywaldron; 07-26-2007 at 10:35 AM.

  2. #2
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,258
    Hello harrywaldron,

    One method would be to use the Split function. This allows you to select the delimiting character, and places the parsed strings into a single dimesion array. This works with Windows 2000 and up.
    Please Login or Register  to view this content.
    This will put "Old" into NameArray(0), and "Chippy" into NameArray(1). You can check the number of elements using the LBound, and UBound methods.

    Sincerely,
    Leith Ross

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1