i'm having a little trouble with defining what my wildcards should be for my conditional statements, i need to ensure that all cells are not "" (null/blank) or MUST be in the form city, state intials (ID) or city, state - street (id)
for example valid strings are newark, nj (1234) or newark, nj - market st. (1234), there might be some text after the ID also
i tried
If activecell.value = "" Or Not (activecell.value Like "*, ?? (*)*"
And Not (activecell.value Like "*, ?? - * (*)*"
Then Exit Do
would this be correct, should that "And" be an "Or",
and should it be "*, ?? (*)*" or "*, ?? (*) *" because im not sure where that last * should be, i keep gettin conflicting results
Also it would help if there is a way of eliminiating extra blanks within my text, i want every word to be seperating by just one blank, i'm trying to match strings so i dotn want to get an error whenever i try to find whether "My String" is equal to "My String" becuase ill get an error, thanks!!!
for example valid strings are newark, nj (1234) or newark, nj - market st. (1234), there might be some text after the ID also
i tried
If activecell.value = "" Or Not (activecell.value Like "*, ?? (*)*"
would this be correct, should that "And" be an "Or",
and should it be "*, ?? (*)*" or "*, ?? (*) *" because im not sure where that last * should be, i keep gettin conflicting results
Also it would help if there is a way of eliminiating extra blanks within my text, i want every word to be seperating by just one blank, i'm trying to match strings so i dotn want to get an error whenever i try to find whether "My String" is equal to "My String" becuase ill get an error, thanks!!!