public void MostrarHermosillo() {
GMapPrueba.Height = 500;
GMapPrueba.Width = 650;
GMapPrueba.setCenter(new GLatLng(29.08919, -110.96133), 12);
GMapPrueba.enableHookMouseWheelToZoom = true;
GMapPrueba.enableGKeyboardHandler = true;
//Adiciona el control de la parte izq superior (moverse, ampliar y reducir)
GMapPrueba.addControl(new GControl(GControl.preBuilt.LargeMapControl));
[Tienes que estar registrado y conectado para ver este vínculo] permite elegir un tipo de mapa y otro.
GMapPrueba.addControl(new GControl(GControl.preBuilt.MapTypeControl));
}
public void MarcarPuntos() {
GLatLng ubicacion = new GLatLng(29.08919, -110.96133);
GMarkerOptions mkrOpts = new GMarkerOptions();
mkrOpts.draggable = false;
mkrOpts.title = "Punto de Localizacion GPS";
mkrOpts.clickable = true;
string strMarker = "<div style='width: 250px; height: 185px'><b>" +
"<span style='color:#ff7e00'>Puntos de Localizacion GPS con </span>ASP.NET</b><br>" +
" C/ Punto No.#1 <br /> Hermosillo, Sonora <br />" +
"Latitud: 29.08919 <br />Longitud: - 110.96133<br />" +
"<br />" +
"<br><br></div>";
GMarker mkr = new GMarker(ubicacion, mkrOpts);
GInfoWindow window = new GInfoWindow(mkr, strMarker, true);
GMapPrueba.addInfoWindow(window);
GMapPrueba.enableHookMouseWheelToZoom = true;
//Tipo de mapa a mostrar
GMapPrueba.mapType = GMapType.GTypes.Normal;
//Moverse con el cursor del teclado
GMapPrueba.enableGKeyboardHandler = true;
GMapPrueba.addGMarker(mkr);
}