if (!Page.IsPostBack) { Map1.MapBackground.BackgroundBrush = new GeoSolidBrush(GeoColor.FromHtml("#E5E3DF")); Map1.CurrentExtent = new RectangleShape(-13939426.6371, 6701997.4056, -7812401.86, 2626987.386962); Map1.MapTools.PanZoomBar.Enabled = true; Map1.MapTools.MouseCoordinate.Enabled = true; Map1.MapUnit = GeographyUnit.Meter; GoogleOverlay google = new GoogleOverlay("Google Map"); google.JavaScriptLibraryUri = new Uri(ConfigurationManager.AppSettings["GoogleUriV3"]); google.GoogleMapType = GoogleMapType.Normal; Map1.CustomOverlays.Add(google); markerOverlay = new InMemoryMarkerOverlay("MarkerOverlay"); markerOverlay.Features.Add("Kansas", new Feature(-10297409, 4814890)); markerOverlay.ZoomLevelSet.ZoomLevel01.DefaultMarkerStyle.WebImage = new WebImage("../../theme/default/img/marker_blue.gif", 21, 25); markerOverlay.ZoomLevelSet.ZoomLevel01.ApplyUntilZoomLevel = ApplyUntilZoomLevel.Level20; Map1.CustomOverlays.Add(markerOverlay); } } InMemoryMarkerOverlay markerOverlay; protected void Map1_Click(object sender, MapClickedEventArgs e) { ((sender as Map).CustomOverlays["MarkerOverlay"] as InMemoryMarkerOverlay).Features.Add(new Feature(e.Position.X, e.Position.Y)); }