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


ITOCBuddyEvents Interface (ArcObjects .NET 10.8 SDK)
ArcObjects Help for .NET developers > ArcObjects Help for .NET developers > ArcObjects namespaces > Controls > ESRI ArcGIS Controls > Interfaces > IT > ITOCBuddyEvents Interface
ArcGIS Developer Help

ITOCBuddyEvents Interface

Provides access to events that notify the TOC of a change.

Product Availability

Available with ArcGIS Engine.

Description

The ITOCBuddyEvents interface can be implemented as an outbound events interface by the Buddy of the TOCControl (e.g. the MapControl). You would only implement this interface if you are creating a control or object that can be a Buddy of the TOCControl. The TOCControl listens to this interface (as well as IActiveViewEvents) in order to refresh maps, layers and symbology, and to re-sync events.

For example, when a new map document is loaded into the MapControl the IActiveView object contained within the MapControl gets replaced. If the MapControl is 'buddied' to a TOCControl, the MapControl fires the ITOCBuddyEvents::ActiveViewReplaced event to the TOCControl. The TOCControl stops listening to events on the 'old' IActiveView object and starts listening to events on the 'new' IActiveView object contained within the MapControl. This ensures the TOCControl automatically reflects the maps, layers and symbology of the Buddy.

Members

Name Description
Method ActiveViewChanged Notifies the TOC that the active view has changed and an Update is required.
Method ActiveViewReplaced Notifies the TOC that the active view has been replaced.

Classes that implement ITOCBuddyEvents

Classes Description
GlobeControl Esri GlobeControl
MapControl Esri MapControl
PageLayoutControl Esri PageLayoutControl
SceneControl Esri SceneControl
TOCBuddyEventsListener (esriSystemUtility) Helper coclass to provide ITOCBuddyEvents support to the C++ API.