IObjectClassEvents_Event not firing events on Undo?

656
1
02-04-2014 01:47 PM
ericliprandi
New Contributor III
Hi,
In our .NET (C#) ArcMap extension, we are successfully listening to Create/Change/Delete events on a feature class (well, a Table).  However, we just realized that an Undo does not trigger the corresponding event.
So basically, if a user edits a row, we get the changed information properly. But then, if they undo their change (Ctrl+Z), we don't get a second event with the appropriate record. This causes our data to be out-of-sync.

What are we missing?

Regards,

Eric.
0 Kudos
1 Reply
deleted-user-VeC5jUIlNXtq
Occasional Contributor III
Hi Eric,

I found your question interesting and decided to have a look.

From the IObjectClassEvents interface help document I found "This type of extension can be used when you don't want to rely on catching IEditEvents...This is handy when you need to implement a geodatabase-level customization that will not be application specific, i.e. dependent upon ArcMap and the Editor extension."

I decided to look at the IEditEvents because "Undo" to me sounds like an application level operation.

Turns out IEditEvents has an OnUndo method. Perhaps that would help solve your problem??

http://resources.arcgis.com/en/help/arcobjects-net/componenthelp/index.html#//00200000009s000000

Anyways, my knowledge is limited, but it sounded interesting and that's what I found.

Cheers,
0 Kudos