Shaggy1
asked on
SQL Server Google Maps Lat/Long C# .net
I need to retrieve Lat/Longitude (which are seperate columns in my sql db) and show them as points in Google Maps in my .net site. I've been looking and looking but can't find any real definitive answer to this. Would appreciate the help. I already have the lat/long so i don't need to use the geocoder. Thanks!
Do you know this component? http://en.googlemaps.subgurim.net/
For integrating google maps into your code you need to access the google
apis.Click on the following lick.
http://code.google.com/apis/maps/index.html
Next step signup the google maps api key and give your website address to generate the unique key for that site.Then it will generate one key for the site. If you use this key to another site it won't work.
Example :
Key is
ABQIAAAAmnOQlz4O2XMui-auz2 pa9BQCy-*
Integrate the following code in your webpages.
Hope this very useful to you.
apis.Click on the following lick.
http://code.google.com/apis/maps/index.html
Next step signup the google maps api key and give your website address to generate the unique key for that site.Then it will generate one key for the site. If you use this key to another site it won't work.
Example :
Key is
ABQIAAAAmnOQlz4O2XMui-auz2
Integrate the following code in your webpages.
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8"/>
<title>Google Maps JavaScript API Example</title>
<script src="http://maps.google.com/maps?file=api&v=2&key=ABQIAAAAmnOQlz4O2XMui-auz2pa9BQCy-*"
type="text/javascript"></script>
<script type="text/javascript">
//<![CDATA[
function load() {
if (GBrowserIsCompatible()) {
var map = new GMap2(document.getElementById("map"));
map.setCenter(new GLatLng(37.4419, -122.1419), 13);
}
}
//]]>
</script>
</head>
<body onload="load()" onunload="GUnload()">
<div id="map" style="width: 500px; height: 300px"></div>
</body>
</html>
Hope this very useful to you.
Also try this link :
http://dotnet.sys-con.com/node/171162
http://dotnet.sys-con.com/node/171162
Cool link for the same :) ------------->>:
http://blog.evonet.com.au/post/Integrating-Google-Maps-into-an-ASPNET-page.aspx
http://blog.evonet.com.au/post/Integrating-Google-Maps-into-an-ASPNET-page.aspx
Another Excellent Link :
http://www.mikeborozdin.com/post/Working-with-Google-Maps-API-in-ASPNET.aspx
http://www.mikeborozdin.com/post/Working-with-Google-Maps-API-in-ASPNET.aspx
ASKER
Thanks for the response. Already familiar with Google API, got my key , etc. I need to be able to retrieve Lat/Long that i have stored in my database and create the points on the map.
ASKER
Just saw the last link , i'll try it out
this might help you....... GoogleMapDemo.aspx.cs
ASKER
nishantcomp2512,
Empty code except references....on that file.
Empty code except references....on that file.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Thanks! This helped.