ArcObjects Component Help  (Core)    

Map CoClass

A container for the display and manipulation of map data.

Interfaces

Interfaces Description
IActiveView Provides access to members that control the active view - the main application window.
IBasicMap Provides access to members that control the basic map.
IConnectionPointContainer
IDisplayAdmin Provides access to members that control display administration.
IDisplayEvents Provides access to members that control Display Events.
IGraphicsContainer Provides access to members that control the Graphics Container.
IGraphicsContainerSelect Provides access to members that control graphic container selection.
IMap Provides access to members that control the map.
IMapAdmin Provides access to Map administration methods.
IMapAdmin2 Provides access to Map administration methods.
IMapBarriers Provides access to members that control map barriers.
IMapBookmarks Provides access to members that control the map bookmarks.
IMapGeographicTransformations Provides access to members that control the map's set of geographic transformations and the directions in which they are applied.
IPersist
IPersistStream
IRelationshipClassCollection Provides access to members that return the memory relationship classes defined for standalone tables or layers in ArcMap.
ISelectionEvents Provides access to events that occur when the selection changes.
IStandaloneTableCollection Provides access to members that control the standalone table collection.
ITableCollection Provides access to members that control a table collection.
ITransformEvents Provides access to members that control Transform Events.
IViewManager Provides access to members used to describe or define view behavior.

Event Interfaces

Interfaces Description
IActiveViewEvents (default) Provides access to events that occur when the state of the active view changes.
IMapEvents Provides access to events that occur when the state of the map changes.

Remarks

A Map object is a container for map data.  A Map object contains layers of both feature and graphic data.

The following is true for the ArcMap application model.  Developers creating their own application may find some things different.

Every map document contains at least one Map object.  Only one Map can have focus at a time and this Map is termed the focus map.  A FocusMap property is conveniently placed on the IMxDocument interface.  IMxDocument also has a Maps property which returns a reference (IMaps) to the entire collection of Maps.  With IMaps you can get a create or delete Maps or get a reference to an existing Map.

All of the layers in a map share the same spatial reference.  The Map's spatial reference is automatically set to the spatial reference of the first layer loaded.  New layers loaded into a Map are projected to the Map's spatial reference if their spatial reference is different.

Map's are contained by MapFrames - the PageLayout object has a MapFrame and a MapFrame has a Map.  Each Map, in turn, has a collection of Layers and MapSurrounds.  Each MapSurround is also associated with a MapSurroundFrame.  There are several types of Layers including FeatureLayers, FDOGraphicsLayers, and GroupLayers.  MapSurrounds include Legends, NorthArrows, and ScaleBars.

Every Map has a Basic Graphics Layer where all graphics including labels are drawn by default.  Users may create additional graphics layers called Groups or Annotation Target Layers all of which are managed by the CompositeGraphicsLayer.

Working with Events

[VB6]

When working with Map's default outbound interface in Visual Basic 6 declare variables as follows:

Private WithEvents pMap as Map

When implementing IMapEvents declare variables as follows:

Private WithEvents pMapEvents as MapEvents

See Also

IMxDocument.FocusMap Property | IMxDocument.Maps Property