Editing features

ArcGIS Viewer for Silverlight provides a simple and intuitive experience for editing features, including changing their geometries and attributes, adding attachments, and creating and deleting them. Editing is available for layers within ArcGIS Server dynamic map services and Spatial Data Service layers (feature layers) if the service was published with feature access enabled. For more information, see Layer types and Publishing feature services.

Once a feature layer has been added to ArcGIS Viewer for Silverlight, editing an existing feature can be done by clicking the feature to display its pop-up. The pop-up includes buttons to add attachments, change the feature's values, edit its geometry, and delete it. See Pop-ups for more information. If your users need to be able to add new features, enable and the Add Features panel included with ArcGIS Viewer for Silverlight. With the Add Features panel, users can create features by selecting the type of feature they wish to add and drawing it on the map.

NoteNote:
While pop-ups on feature layers can be configured to show up on hover or on click, the editing tools are only available for on-click pop-ups. If editing is enabled for a feature layer, that layer's pop-ups will only be displayed on click.

For additional information, see Editing features in the ArcGIS API for Silverlight Help and Authoring feature services in the ArcGIS Server Help.

Configuring editing

Editing for feature layers is not enabled by default in the ArcGIS Viewer for Silverlight. This ensures that only the desired layers can be edited by your users. You can choose which layers can be edited, as well as other editing options, as follows:

  1. Click the Configure button on the Tools tab of the Application Builder toolbar.
    Configure button on Tools tab
  2. In the Configure Controls dialog box, click the Editng link to open the Configure Editing dialog box.
    Configure Controls dialog box
  3. In the Configure Editing dialog box, select the layers to edit. Only layers that support editing will be shown here. If you select the option to edit all feature layers, editing will automatically be enabled on any layers added to the map which support editing.
    Select layers to edit
    NoteNote:

    Editing cannot be enabled for layers that have clustering applied. If you attempt to enable editing on a clustered layer, you will be prompted to turn off clustering.

  4. Click Next to show the editing options.
  5. Check the box next to any of the editing options you want to enable, then click OK to close the Configure Editing dialog box.
    Choose editing options
    NoteNote:

    The Advanced Editing Tools section contains tools intended for power users with advanced editing scenarios. When enabled, these appear on a toolbar at the bottom of the the Add Features panel.

Once you have specified the layers to edit, the pop-ups for those layers will include the following editing tools:

On-click pop-up window with editing tools

Adding new features

If your users need to be able to create new features, add the Editing tool to a Viewer toolbar (see Adding and managing tools and toolbars for information). The Editing tool opens the Add Features panel, which displays the types of features that can be created.

NoteNote:
The feature types displayed in the Add Features panel are defined by the feature templates that were published with the map service (see About feature templates and Publishing feature services). These feature types define the symbol and set of default attributes that will be used when a feature is created.

You can create features using the Add Features panel as follows:

  1. Configure editing using the steps in the Configuring editing section of this topic.
  2. Click the Editing tool you added to the Viewer toolbar. The Add Features panel appears.
    Add Features panel
  3. The types of features you can create are displayed in the Add Features panel. If you do not see types for a layer that you wish to edit, ensure that editing is enabled for that layer. You can click Configure Editing at the bottom of the Add Features panel to check this.
  4. Click the type of feature you wish to add.
  5. Draw the feature on the map. If you are adding a point feature, simply click once on the map to draw the feature. If you are adding a line or polygon feature, single-click to add vertices, then double-click to complete the feature.
  6. Once you are done drawing the feature, its pop-up will open so that you can edit the feature's attributes. Simply type the desired values or select them from the drop-down menus and date pickers that appear.
  7. Click the Apply button to save the feature.

TipTip:

If editor tracking is enabled on the service being edited, the Viewer will automatically record the identity of users who create or edit features. Note that this functionality can only be managed on the service itself; it cannot be enabled or disabled from within the Viewer.

1/26/2015