rvinc

EditorWidget not working

Discussion created by rvinc on Oct 23, 2012
Latest reply on Oct 25, 2012 by rvinc
I'm sure I'm doing something wrong. I have a map package with point featureclasses stored in it. I've adding the map package programmatically but now I'm trying to edit one of these point featureclasses. I've added the EditorWidget programmatically but how do I get it to edit my featureclass? Also, how do I get a reference the particular featureclass in the map package?

            LocalMapService localMapServiceTactical = new LocalMapService()
            {
                Path = @"C:\Data\tactical.mpk",
                EnableDynamicLayers = true
            };

            // Start the local map service and once initialized
            localMapServiceTactical.StartAsync((mapService) =>
            {

                // create a new local dynamic map service layer based on the local map service
                _arcGISLocalDynamicMapServiceLayer = new ArcGISLocalDynamicMapServiceLayer(localMapServiceTactical)
                {
                    ID = "Tactical",
                    ImageFormat = ArcGISDynamicMapServiceLayer.RestImageFormat.PNG32,
                };

                // Set up an event handler for the layer initialized event
                _arcGISLocalDynamicMapServiceLayer.Initialized += (s, e) =>
                {
                    //Enable the UI once the layer has initialized
                    //DynamicLayersUiGrid.IsEnabled = true;
                    DataContext = this;
                    //IsBusy = false;
                };


                // Add the layer to the map
                _map.Layers.Add(_arcGISLocalDynamicMapServiceLayer);
            });

Thanks,

Ron

Outcomes