This document is archived and information here might be outdated.  Recommended version.


IMap.DelayEvents Method (ArcObjects .NET 10.8 SDK)
ArcObjects Help for .NET developers > ArcObjects Help for .NET developers > ArcObjects namespaces > Carto > ESRI.ArcGIS.Carto > Interfaces > IM > IMap Interface > IMap.DelayEvents Method
ArcGIS Developer Help

IMap.DelayEvents Method

Used to batch operations together to minimize notifications.

[Visual Basic .NET]
Public Sub DelayEvents ( _
    ByVal delay As Boolean _
)
[C#]
public void DelayEvents (
    bool delay
);
[C++]
HRESULT DelayEvents(
  VARIANT_BOOL delay
);
[C++]
Parameters
delay [in]

delay is a parameter of type bool

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Remarks

All calls made to IActiveViewEvents::SelectionChanged are ignored when DelayEvents is set to TRUE.  The event is automatically fired when DelayEvents is set back to FALSE to ensure that clients ultimately receive the event.

This method is typically used when changing the Map's selection.  Without DelayEvents set to TRUE, the SelectionChanged event would fire each time a feature is added or removed; instead, DelayEvents is used so that only one notification is sent when the entire selection operation is complete.

See Also

IMap Interface