ArcObjects Library Reference (Controls)  

IMapControl3 Interface

Provides access to members that control the MapControl. Note: the IMapControl3 interface has been superseded byIMapControl4. Please consider using the more recent version.

Product Availability

Available with ArcGIS Engine.

Description

The IMapControl3 interface provides additional members for tasks related to the MapControl, such as setting a custom property and suppressing data redraw whilst the MapControl is being resized.
 

Members

Description
Method AboutBox Displays a dialog of information about the MapControl.
Method AboutBox Displays a dialog of information about the MapControl.
Read-only property ActiveView The active view of the Map contained by the MapControl.
Read-only property ActiveView The active view of the Map contained by the MapControl.
Method AddLayer Adds a layer to the Map's collection of layers at the specified index position.
Method AddLayer Adds a layer to the Map's collection of layers at the specified index position.
Method AddLayerFromFile Loads a layer file and adds it to the Map's collection of layers at the specified index position.
Method AddLayerFromFile Loads a layer file and adds it to the Map's collection of layers at the specified index position.
Method AddShapeFile Adds a shapefile as a layer to the Map.
Method AddShapeFile Adds a shapefile as a layer to the Map.
Read/write property Appearance The appearance of the MapControl.
Read/write property Appearance The appearance of the MapControl.
Read/write property BackColor Background color of the MapControl.
Read/write property BackColor Background color of the MapControl.
Read/write property BorderStyle The border style of the MapControl.
Read/write property BorderStyle The border style of the MapControl.
Method CenterAt Moves the center of the MapControl to the specified location.
Method CenterAt Moves the center of the MapControl to the specified location.
Method CheckMxFile Checks the specified filename to see if it is a map document that can be loaded into the MapControl.
Method CheckMxFile Checks the specified filename to see if it is a map document that can be loaded into the MapControl.
Method ClearLayers Removes all layers from the Map.
Method ClearLayers Removes all layers from the Map.
Read/write property CurrentTool Current active tool for the MapControl. Set to nothing to clear the tool.
Read/write property CurrentTool Current active tool for the MapControl. Set to nothing to clear the tool.
Read/write property CustomProperty A property to associate data with a control.
Method DeleteLayer Removes a Layer from the Map's collection of layers at the specified index position.
Method DeleteLayer Removes a Layer from the Map's collection of layers at the specified index position.
Read/write property DocumentFilename The filename of the last map document loaded into the control.
Read/write property DocumentMap The name of the map that was last loaded into the control from a map document.
Method DrawShape Draws a geometry shape on the MapControl.
Method DrawShape Draws a geometry shape on the MapControl.
Method DrawText Draws text along the supplied geometry.
Method DrawText Draws text along the supplied geometry.
Read/write property Enabled Indicates whether the MapControl can respond to user generated events.
Read/write property Enabled Indicates whether the MapControl can respond to user generated events.
Read/write property Extent Current extent of the Map in map units.
Read/write property Extent Current extent of the Map in map units.
Method FlashShape Flashes a shape on the MapControl, duration is in milliseconds.
Method FlashShape Flashes a shape on the MapControl, duration is in milliseconds.
Method FromMapPoint Converts a point on the Map (in map units) to device co-ordinates (typically pixels).
Method FromMapPoint Converts a point on the Map (in map units) to device co-ordinates (typically pixels).
Read/write property FullExtent Rectangular shape that encloses all features of all layers in the Map.
Read/write property FullExtent Rectangular shape that encloses all features of all layers in the Map.
Read-only property hWnd Handle to the window associated with the MapControl.
Read-only property hWnd Handle to the window associated with the MapControl.
Read/write property KeyIntercept A property that specifies interception of key strokes that are normally handled by the container. When intercepted the OnKeyDown and OnKeyUp events will be called. This value can be a combined bit mask of esriKeyIntercept enum values.
Read-only property Layer Layer at the supplied index.
Read-only property Layer Layer at the supplied index.
Read-only property LayerCount Number of layers in the Map.
Read-only property LayerCount Number of layers in the Map.
Method LoadMxFile Loads the specified Map from the map document into the MapControl. The Map can be an index or a name, if it is not supplied the focus map is used.
Method LoadMxFile Loads the specified Map from the map document into the MapControl. The Map can be an index or a name, if it is not supplied the focus map is used.
Read/write property Map The Map contained by the MapControl.
Read/write property Map The Map contained by the MapControl.
Read/write property MapScale Scale of the map as a representative fraction.
Read/write property MapScale Scale of the map as a representative fraction.
Read/write property MapUnits The geographical units of the map.
Read/write property MapUnits The geographical units of the map.
Read/write property MouseIcon Custom mouse icon used if MousePointer is 99.
Read/write property MouseIcon Custom mouse icon used if MousePointer is 99.
Read/write property MousePointer The mouse pointer displayed over the MapControl.
Read/write property MousePointer The mouse pointer displayed over the MapControl.
Method MoveLayerTo Moves a layer within the Map's collection from its current index position to a new index position.
Method MoveLayerTo Moves a layer within the Map's collection from its current index position to a new index position.
Read-only property Object A property that returns the underlying control. This can be used when the control is inside a wrapper object that has been added by a development environment.
Read/write property OleDropEnabled Indicates if the MapControl will fire events when data is dragged over the control's window.
Read/write property OleDropEnabled Indicates if the MapControl will fire events when data is dragged over the control's window.
Method Pan Tracks the mouse while panning the MapControl.
Method Pan Tracks the mouse while panning the MapControl.
Method ReadMxMaps Opens a map document specified by the supplied filename and reads the maps into an array object.
Method ReadMxMaps Opens a map document specified by the supplied filename and reads the maps into an array object.
Read/write property ReferenceScale Reference scale of the Map as a representative fraction.
Read/write property ReferenceScale Reference scale of the Map as a representative fraction.
Method Refresh Redraws the Map, optionally just redraw specified phases or envelope.
Method Refresh Redraws the Map, optionally just redraw specified phases or envelope.
Read/write property Rotation Determines how many degrees the map display is rotated.
Read/write property Rotation Determines how many degrees the map display is rotated.
Read/write property ShowMapTips Indicates if map tips are shown.
Read/write property ShowScrollbars Indicates whether or not the Map's scrollbars are visible.
Read/write property ShowScrollbars Indicates whether or not the Map's scrollbars are visible.
Read/write property SpatialReference Spatial reference of the Map.
Read/write property SpatialReference Spatial reference of the Map.
Method SuppressResizeDrawing Suppress full redraw of control during resize operations.
Read/write property TipDelay The delay before map tips are shown.
Read/write property TipStyle The style of map tips.
Method ToMapPoint Converts a point in device co-ordinates (typically pixels) to a point on the Map (in map units).
Method ToMapPoint Converts a point in device co-ordinates (typically pixels) to a point on the Map (in map units).
Read/write property TrackCancel The object used by the MapControl to check if drawing has been aborted.
Read/write property TrackCancel The object used by the MapControl to check if drawing has been aborted.
Method TrackCircle Rubber-bands a circle on the MapControl.
Method TrackCircle Rubber-bands a circle on the MapControl.
Method TrackLine Rubber-bands a polyline on the MapControl.
Method TrackLine Rubber-bands a polyline on the MapControl.
Method TrackPolygon Rubber-bands a polygon on the MapControl.
Method TrackPolygon Rubber-bands a polygon on the MapControl.
Method TrackRectangle Rubber-bands a rectangle on the MapControl.
Method TrackRectangle Rubber-bands a rectangle on the MapControl.
Write-only property VisibleRegion The geometry specifying the visible region of the Map.
Write-only property VisibleRegion The geometry specifying the visible region of the Map.

CoClasses that implement IMapControl3

CoClasses and Classes Description
MapControl Esri MapControl
[C#]

When querying interface to IMapControl3 in Visual Basic .NET or Visual C# .NET the Object property or container specific code must be used. This is because .NET contains the real control inside a wrapper object known as an host.

IMapControl3 mapControl = axMapControl1.Object as IMapControl3;

[Visual Basic .NET]

When querying interface to IMapControl3 in Visual Basic .NET or Visual C# .NET the Object property or container specific code must be used. This is because .NET contains the real control inside a wrapper object known as an host.

Dim mapControl As IMapControl3 = AxMapControl1.Object

.NET Samples

Editing using a custom form (Code Files: EditorForm MainForm) | Network Analyst Engine application (Code Files: cmdClearAnalysisLayer cmdLoadLocations cmdNALayerProperties cmdRemoveLayer frmLoadLocations frmMain) | Displaying a TOCControl context menu (Code Files: LayerSelectable RemoveLayer ScaleThresholds TOCContextMenuForm) | Synchronized MapControl and PageLayoutControl application (Code Files: ControlsSynchronizer frmMain) | GraphicTracker with the map (Code Files: GTMapForm) | Simple dynamic display application (Code Files: CreateNewDocument MainForm) | Implementing a property page for an ArcGIS Engine application (Code Files: CreateNewDocument frmMain) | Save a layer file in a MapControl application (Code Files: CreateNewDocument frmMain LoadLayerFileCmd RemoveLayerCmd SaveLayerFileCmd) | Schematics Engine application (Code Files: CreateNewDocument MainForm RemoveLayer) | Temporal statistics (Code Files: CreateNewDocument MainForm)