String Manipulation

mark curtis

Registered User.
Local time
Today, 23:51
Joined
Oct 9, 2000
Messages
457
I have a string called strEmail as follows:

me.me@comp.co.uk,you.you@comp.co.uk, etc

What I need to do is strip off the comma at the very end of the string.

I have tried left, len and all the rest, can anyone help?

Thanks
Mark
 
Are you trying to populate a new table with the addresses?

One way I can think of to do it would be to set an Integer value to the location of the first comma (using InStr([start],string to search in, string to search for, comparison type)) and then take part to the left of that as the email address and the part to the right as the new strEmail and repeat the process until finished.
 
Last edited:
strCur = Trim$(strCur)

loStrLen = Len( strCur )

if Right$( strCur, 1 ) = "," then
strCur = Left$( strCur, loStrLen - 1 )
End If


This will leave all embedded commas alone.
 
Oh...I see...it helps to read the original question well. :D

Hey, if you ever need to have all of the addresses seperate, I'm glad I could help.
 

Users who are viewing this thread

Back
Top Bottom