Monday, 17 October 2011

How to add gmap in asp.net

Code:
using System.Configuration;
using Subgurim;
using Subgurim.Controles;

-------------------------------------------------------
write this code in page load

{
        Subgurim.Controles.GLatLng gLatLng = new Subgurim.Controles.GLatLng(17.427231, 78.434578);//(17.427239, 78.43465);
        GMap1.setCenter(gLatLng, 16, GMapType.GTypes.MapMaker_Normal);
        GMap1.enableContinuousZoom = true;
        var omarker = new Subgurim.Controles.GMarker(gLatLng);
        GInfoWindow gmapinfo = new GInfoWindow(omarker, "<center><b>Sarayu Global Solutions</b><br>Plot No 590,Arora Colony,<br>Road No 3,Bangara Hills,HYD. </center>", true);
        GMap1.addInfoWindow(gmapinfo);
    }


----------------------------------------------------------------
Write this code in web.confg

<appSettings>
        <add key="GoogleMaps.Subgurim.net" value="ABQIAAAArKrLXt1alkjaZVnVCX8HCBSIhkdEuHkMXwkldojWLYSyEi8CBBTII70OuHyyc2uZtSvSJVQuvUTdAg"/>
        <add key="Chart Image Handler" value="Storage=file,Time Out=20"/>
        <add key="google"/>
    </appSettings>
---------------------------------------------------------------
                 enjoy the coding if u hd any doubts r if u like my post contact me....