Question : Abbreviate addresses using replace formula

CRV 10 - I need to modify an existing address formula to also change certain text to standard postal abbreviations.  For example replace ROAD with RD, replace STREET with ST, replace AVENUE with AVE.  I think I  need to use the replace function, but so far can't get it to work.  How can I modify my existing formula to accomplish this?  Thanks

uppercase({EMPLOYEE.ADDR1}&' '&{EMPLOYEE.ADDR2})

Answer : Abbreviate addresses using replace formula

I'm not sure of the upper limits, but I'm sure you'll get an error like "too many nested somethings".  You may want to do it like this, it's easier to read, too:

stringvar replaceme;

replaceme := Replace(uppercase({EMPLOYEE.ADDR1}&' '&{EMPLOYEE.ADDR2}),"STREET","ST");
replaceme := Replace(Replaceme,"AVENUE","AVE");
replaceme := Replace(Replaceme,"ROAD","RD");
replaceme := Replace(Replaceme,"ETC.","ETC");
...
replaceme


Random Solutions  
 
programming4us programming4us