function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
SriSaiSriSai 

To Create a VF page to get Latitude and Longitude !!!

I'm new to VF and I'm looking for some one who can help me in creating a VF page to get the Latitutde and Longitude when a city and state are entered using Google’s Geocoding  xml API and salesforce xml.

colemabcolemab

If you want to plot more than one location, it is probably best to cache out the geo coding (long/lat) data using a geocoder engine or trigger.

 

If you are wanting to display just one point on a map, you will want to use visual force to pass the data to java script and have java script make the call.  This page isn't exactly what you want but has some similar examples (VF+javascript to google from caching) and includes a link to this page that shows you how to do the caching in real time.

 

Good luck and may the force be with you.