Hello all!
First post from a VBA dabbler/beginner incoming.
I'm attempting to write a function that will look at a user-generated street address and "fix" it by:
a) Correctly abbreviating everything that can be abbreviated,
b) Removing unnecessary punctuation, and
c) To a lesser extent, correcting common spelling errors.
So "1234 East Rumson Raod" becomes "1234 E Rumson Rd".
The function has to be able to handle multiple variations of the same theme (ie. "Street", "St.", "Str", "Str." all become "St"). That said, I'm not trying to catch everything right off the bat. Right now, I'm trying to use the following:
Unfortunately the code above returns nothing. I also just read that the Replace function only returns the string up to the end of the replaced portion, so even if it was returning something it probably wouldn't be correct.
Can anyone tell me why that above returns nothing, and point me in the direction of a function that will return an entire string after part of it has been replaced?
Thanks all!
RA
Bookmarks