read marker Longitude and Latitude from MS SQL Database

Topics: Etc...
Nov 13, 2011 at 1:38 PM

Hello,

I am new to gmap.net and programming in general. I was wondering how can i read several longitude and Latitude from a MS SQL Database and add it to markers in my control map? I have my map already setup with my basic setups. I just want someone to point me in there right track with a similar code or etc.

 

Thanks,

Coordinator
Nov 13, 2011 at 1:42 PM

http://msdn.microsoft.com/en-us/library/bb425822.aspx

Nov 13, 2011 at 1:46 PM

I know how to get my SQL table into a dataset in vb.net but then i dont know how to go 1 by 1 adding each marker and reading from the dataset

Coordinator
Nov 13, 2011 at 1:54 PM

;}

Nov 13, 2011 at 2:04 PM

Can someone show a sample code!

Nov 15, 2011 at 6:14 AM
foreach(var gpsPoint in dataset.GPSTable)
{
     PointLatLng point = new PointLatLng(gpsPoint.Lat, gpsPoint.Long);
     GMapMarkerGoogleRed marker = new GMapMarkerGoogleRed(point); 
     yourOverlay.Markers.Add(marker);

}

 

 

 

Nov 17, 2011 at 1:56 AM

Perfect that's what i was looking for.

Thanks! xandolph