ThinkGeo.com    |     Documentation    |     Premium Support

Topography Data

Hi,


  How would one go about getting topography data to show in the Desktop Edition being served by our WMS Server. 


Thanks,


  Steven



Steven,


Please refer the following code for your requirements:


 



winformsMap1.MapUnit = GeographyUnit.Meter;
            winformsMap1.BackgroundOverlay.BackgroundBrush = new GeoSolidBrush(GeoColor.GeographicColors.ShallowOcean);

            WfsFeatureLayer wfsFeatureLayer = new WfsFeatureLayer(@"giswebservices.massgis.state.ma.us/geoserver/wfs?request=GetFeature", "massgis:TOWNS_POLYM");
            wfsFeatureLayer.ZoomLevelSet.ZoomLevel01.DefaultAreaStyle = AreaStyles.State1;
            wfsFeatureLayer.ZoomLevelSet.ZoomLevel01.ApplyUntilZoomLevel = ApplyUntilZoomLevel.Level20;

            LayerOverlay staticOverlay = new LayerOverlay();
            staticOverlay.Layers.Add("WfsFeatureLayer", wfsFeatureLayer);
            winformsMap1.Overlays.Add(staticOverlay);

            winformsMap1.CurrentExtent = ExtentHelper.GetDrawingExtent(new RectangleShape(211194.773023808, 900714.685933739, 267656.174822514, 877748.629256157), winformsMap1.Width, winformsMap1.Height);
            winformsMap1.Refresh();
This is just a sample for you, you need to change the wfs link and type name when creating the WfsFeatureLayer. If you encountered any problems please us know again,


Thanks,


Scott,