Help tracking ArcGIS edits via events.

1337
3
10-23-2020 02:48 PM
ShawnPacarar
New Contributor

I am working on a project as part of the esri startup program and I’m using the ArcGIS Pro SDK in attempts to see all edits that happen in the same edit session.
To do this I’m hooking into some of the events that the SDK provides, but I haven’t found a robust way to link multiple operations. Currently, I can see a Guid during an EditStartedEvent and a Guid in an EditCompletingEvent, but no such id during an of the EditCompletedEvents which has data that was changed.

The problem I'm having is that sometimes multiple, or no, EditCompletedEvents are fired after the EditCompletingEvent giving me no concrete pattern to look for indicating that the edits within that EditCompletedEvent are related to the EditStartedEvent or other EditCompletedEvents. Does anyone have any additional information for how this could be achieved?

The goal is to gather information about which edits happened within the same edit-session.

0 Kudos
3 Replies
KoryKramer
Esri Community Moderator
0 Kudos
by Anonymous User
Not applicable

Shawn,

EditCompletedEventArgs will give you the changes during an individual edit but not what made those changes. To keep track of the changes during a Pro session, you would have to aggregate these changes. The EditCompletedEvent will fire for individual edits but also for save, discard, undo, redo etc. For each individual edit you should also get one EditStartedEvent and one EditCompletingEvent. Since you mention guid a few times what are you hoping to record?

The datachanges class from ArcObjects has not yet been ported.

0 Kudos
ShawnPacarar
New Contributor

I think there was some confusion among our team about the nature of edits. I had thought that it was more along the lines of start edit session -> make edits -> save/discard edits closing edit session. Since edits seem to be more singular what you've said makes a lot of sense to me. Our team also spoke with some people on the Esri Startups Slack that have provided some insights on how to gather the information we were looking to procure for our app.

0 Kudos