>lcString = 'Sauk Rapids, MN 56379' > >* First get out all of the multiple spaces and junk out. >lcString = chrtran(lcString, ',' + chr(9), space(2)) >do while space(2) $ lcString > lcString = StrTran(lcString, space(2), space(1)) >enddo > >lnStartZip = rat(space(1), lcString) + 1 >?'Zip: ' + substr(lcString, lnStartZip) >lnStartState = rat(space(1), lcString, 2) + 1 >?'State: ' + substr(lcString, lnStartState, lnStartZip - lnStartState) >?'City: ' + substr(lcString, 1, lnStartState - 2)Your code is wonderful for the example you undertook to parse. The thread originator needs to provide us some samples of the "mess" if we're going to be able to give him any meaningful guidance.