Thread: Name Manipulation
11-11-02, 12:08 #1Registered User
- Join Date
- Nov 2002
- Birmingham, AL
Unanswered: Name Manipulation
First I should say I am not familiar with Visual Basic.
I am trying to break up a name field with various name formats into 2 separate fields:
1. firstname and initial, if included
2. lastname, and suffix if included
The various name formats are similar to these:
Mr. & Mrs. John R. Smith, III
Mr. Henry B. Jones & Ms. Hillary Loper
Kay M Conroy Peckham
Thomas F & Joyce Mlyniec
J. Smith, MD
Can anyone help?
11-11-02, 12:27 #2Registered User
- Join Date
- Oct 2002
- Leicester - UK
easily done in VB
though not what yout looking for this is something i've done resently it's designed to append a '&' sign between the last 2 elements of a list instead of a comma
Message = (Left$(Message, InStrRev(Message, ",") - 1) & " &" & Right$(Message, Len(Message) - InStrRev(Message, ",")))
the commands you need are Left$, Right$ and Instr (or InStrRev if you inclued middle names and want the surname)
you will need to screen the MR, MRS, MD, etc from them first, if they're vital store them in a variable and remerge it later
if you cant figure the code drop me a Email and i'll try to lend a handDefinition of a Beginner, Someone who doesn't know the rules.
Definition of an Expert, Someone who knows when to ignore the rules.