I am using GoogleMaps API in my C# webservices application. I have a webpage where the user enters address involving streetline1, streetline2, city, state, zipcode. The method i have written accepts this address and returns latitude/longitude (Geocoding). The problem i am facing is its not validating the entire address. Say for eg. i am trying to get geocode for a valid address No 1 Main Street, Chicago, IL, 60612 it returns a valid lat/long. And if i change the address to No 1 Main Street, San Jose, CA, 60612 it still returns the same geocode. I am suspecting its taking only the StreeLine1 and Zipcode to obtain geocode. Is my understanding right? If so if i give such invalid address but valid Addressline1 and zipcode it still gives lat/long- how can i handle this problem?
Asked
Active
Viewed 256 times
0
-
1You can have a look here. It is the same question. http://stackoverflow.com/questions/682093/address-validation-api – Sethu Jun 27 '12 at 11:57
1 Answers
1
The geocoder is not an address verifier. It returns the best match(es) for a given input. Perhaps you are getting multiple results. I don't get the same coordinates for the two examples you provided.

geocodezip
- 158,664
- 13
- 220
- 245
-
Thanks for your response. Yeah i agree with you, we are getting 2 different coordinates for the examples. But if you see zipcode of San jose CA is not 60612. Which all attributes it is considering for obtaining the geo coordinates? And in general how to validate the correctness of the address if not by GeoCoder? I mean is it possible? – Vinoth Jun 27 '12 at 11:01
-
As I said, the geocoder is not an address verifier. If you know the approximate location where the result should be, you can check the distance from that location. Are you getting multiple results from the geocoder? – geocodezip Jun 27 '12 at 12:39