ArcObjects Library Reference (Controls)  

IEngineEditEvents Interface

Provides access to the EngineEditor's events.

Product Availability

Available with ArcGIS Engine.

Description

This interface is new at ArcGIS 9.3.

Implement IEngineEditEvents to listen for specific events that occur during an edit session.

The following code example creates a listener to determine when an editing session has started. For more information refer to the "How to listen to edit events" and "How to wire ArcObjects.NET events" documents.

Members

Description
Event OnAbort Fires when an edit operation is aborted.
Event OnAfterDrawSketch Fires after the edit sketch is drawn.
Event OnBeforeStopEditing Fires before editing stops.
Event OnBeforeStopOperation Fires before an edit operation stops.
Event OnChangeFeature Fires when features are modified.
Event OnConflictsDetected Fires when editing conflicts are detected during save.
Event OnCreateFeature Fires when new features are created.
Event OnCurrentTaskChanged Fires when the current task changes.
Event OnCurrentZChanged Called when the CurrentZ changes.
Event OnDeleteFeature Fires when features are deleted.
Event OnSaveEdits Fires when edits are saved.
Event OnSelectionChanged Fires when the selection changes.
Event OnSketchFinished Fires when the edit sketch is finished.
Event OnSketchModified Fires when the edit sketch is modified.
Event OnStartEditing Fires when editing begins.
Event OnStartOperation Fires when an edit operation starts.
Event OnStopEditing Fires when editing ends.
Event OnStopOperation Fires when an edit operation stops.
Event OnTargetLayerChanged Fires when the target layer changes.
Event OnVertexAdded Fires when a vertex is added to the edit sketch.
Event OnVertexDeleted Fires when a vertex is deleted from the edit sketch.
Event OnVertexMoved Fires when a vertex is moved in the edit sketch.

CoClasses that implement IEngineEditEvents

CoClasses and Classes Description
EngineEditor A singleton object representing the Engine editing environment.
[C#]

Private EngineEditor m_EngineEditor = new EngineEditorClass();
private IEngineEditEvents_Event m_EngineEditEvents;

private void MainForm_Load(object sender, EventArgs e)
{
    m_EngineEditEvents = (IEngineEditEvents_Event)m_EngineEditor;
    m_EngineEditEvents.OnStartEditing += new IEngineEditEvents_OnStartEditingEventHandler(OnStartEditingMethod);
}

private void OnStartEditingMethod()
{
  System.Windows.Forms.MessageBox.Show("Editing Started");
}

[Visual Basic .NET]

Private m_EngineEditor As EngineEditor = New ESRI.ArcGIS.Controls.EngineEditorClass()
Private m_EngineEditEvents As IEngineEditEvents_Event

Private Sub MainForm_Load(ByVal sender As System.Object, ByVal e As EventArgs) Handles MyBase.Load
    m_EngineEditEvents = CType(m_EngineEditor, IEngineEditEvents_Event)
    AddHandler m_EngineEditEvents.OnStartEditing, AddressOf OnStartEditingMethod
End Sub

Private Sub OnStartEditingMethod()
  System.Windows.Forms.MessageBox.Show("Editing Started")
End Sub