Altova Mailing List Archives>Archive Index >microsoft.public.xml Archive Home >Recent entries [Thread Prev] >Thread Next - RE: Parse Street Address Parse Street AddressTo: NULL Date: 12/4/2006 2:03:00 PM We are currently parsing XML into our .NET application (written in C#). The AddressLine1 we receive is entered free-form and we are parsing this into StreetNumber, StreetName, StreetType and StreetDirection. Here is the current logic: CASE 1: If AddressLine1 has 3 parts, we parse into StreetNumber, StreetName, and StreetType. If the first 3 characters from the StreetType, match the street type values in our dataset, we display the correct StreetType, otherwise we dump the entire AddressLine1 into StreetName and leave the user to "fix" this if you will. If any exceptions occur during parsing, we also dump the entire AddressLine1 into StreetName. CASE 2: If AddressLine1 has <3 or >3 parts, we dump the entire AddressLine1 into StreetName. This logic was inherited from a previous application and as you can see, this logic doesn't work the majority of the time. I need HELP in locating a function, script or "something" that can make more sense of this. I realize that it will only ever be 80% effective at best but there has to be a better solution out there. HELP!! Thanks. | ||||||
| Company | Legal | Press | Partners | Careers | Sitemap | Contact Us | Altova Blog | Mobile | Full Site | |||
|
