private void DisplayMap_Load(object sender, EventArgs e) { winformsMap1.MapUnit = GeographyUnit.DecimalDegree; winformsMap1.BackgroundOverlay.BackgroundBrush = new GeoSolidBrush(GeoColor.GeographicColors.ShallowOcean); WorldMapKitWmsDesktopOverlay wmsOverlay = new WorldMapKitWmsDesktopOverlay(); winformsMap1.Overlays.Add(wmsOverlay); LayerOverlay overLay = new LayerOverlay(); inmLayer = new InMemoryFeatureLayer(); inmLayer.ZoomLevelSet.ZoomLevel01.DefaultPointStyle = PointStyles.Capital1; inmLayer.ZoomLevelSet.ZoomLevel01.ApplyUntilZoomLevel = ApplyUntilZoomLevel.Level20; Random random = new Random(); for (int i = 0; i < 11000; i++) { inmLayer.InternalFeatures.Add(new Feature(random.Next(-180, 180), random.Next(-180, 180))); } overLay.Layers.Add(inmLayer); winformsMap1.Overlays.Add(overLay); winformsMap1.CurrentExtent = new RectangleShape(-139.2, 92.4, 120.9, -93.2); winformsMap1.Refresh(); winformsMap1.MouseHover += new EventHandler(winformsMap1_MouseHover); } InMemoryFeatureLayer inmLayer; int counter = 0; void winformsMap1_MouseHover(object sender, EventArgs e) { if (counter==0) { inmLayer.ZoomLevelSet.ZoomLevel01.DefaultPointStyle = PointStyles.City3; counter = 1; } else { inmLayer.ZoomLevelSet.ZoomLevel01.DefaultPointStyle = PointStyles.Capital1; counter = 0; } winformsMap1.Refresh(); }