Skip to content
Branch: master
Find file History
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
..
Failed to load latest commit information.
DarkImages
Dockpane
Images
Properties
Screenshots
Config.daml
EditEvents (C#).md
EditEvents.csproj
EditEvents.sln
Module1.cs
ReadMe.md

ReadMe.md

EditEvents

The EditEventsSpy dockpane listens to the editing Row, Completing, and Completed events

View it live

Language:              C#
Subject:               Editing
Contributor:           ArcGIS Pro SDK Team <arcgisprosdk@esri.com>
Organization:          Esri, http://www.esri.com
Date:                  6/27/2019
ArcGIS Pro:            2.4
Visual Studio:         2017, 2019
.NET Target Framework: 4.6.1

Resources

ArcGIS Pro SDK for .NET Icons

Samples Data

  • Sample data for ArcGIS Pro SDK Community Samples can be downloaded from the repo releases page.

How to use the sample

  1. Download the Community Sample data (see under the 'Resources' section for downloading sample data). The sample data contains required data for this sample add-in. Make sure that the Sample data is unzipped in c:\data and "C:\Data\Interacting with Maps" is available.

  2. In Visual Studio click the Build menu. Then select Build Solution.

  3. Click Start button to open ArcGIS Pro.

  4. ArcGIS Pro will open.

  5. Open the "C:\Data\Interacting with Maps\Interacting with Maps.aprx" project which contains the required data needed for this sample.

  6. Make sure "Portland Crimes" is the active map and the "Contents" dockpane is open.

  7. Select "Crimes" on the Contents table of content.

  8. From the "Add-in" tab select "Show EditorEventsSpy".
    UI

  9. Click Start Events to start listening for the edit events. Click the Create, Change, or Delete buttons to execute edits that trigger the events.

  10. They will be reported to you on the EditEventsSpy dockpane 'as they happen'.

    UI

  11. Check the Cancel edits, Validate edits, and Fail validation checkboxes (in any combination) to apply that action in the respective row event handler. Note that canceling the edit or canceling the edit because of failed validation terminates the entire edit operation and no further events fire for that operation.

  12. By default, the Create will create two features so you can see the two row events.
    UI

  13. The created features will be selected so clicking Change or Delete will apply the respective edit to the newly created features. Feel free to select others.

  14. You can also try commenting out the cancel logic in the row event handler and, instead, canceling the edit in the EditCompletingEvent.

      ArcGIS Pro SDK for Microsoft .NET Framework              Home | API Reference | Requirements | Download | Samples

You can’t perform that action at this time.