views:

789

answers:

2

Hi

does anyone have a snippet of sample code to get country and state/city via the Google Maps API of a request from an asp.net application (in code behind)?

Any help much appretiated!

Thanks!

A: 

The Google Maps API has a great HTTP geocoding service. You can get your response in JSON, KML, or CSV. I'm not familiar with ASP.NET, but I'm sure you can find a function to send and process a HTTP Request.

Chris B
A: 

I think the short answer to this is you can't use Google Maps API to take an IP and lookup a city/region.

The API only lets you Geocode a place-name or the like - i.e. take "New York" and it'll give you back a long/lat.

db1234