Share via


SelectedArea property

Returns the selected area (SelectedArea object) for the specified map. Read-only.

Applies to

Objects: Map

Syntax

object.SelectedArea

Parameters

Part

Description

object

Required. An expression that returns a Map object.

Example

  Sub UseSelectedAreaProperty()
 
  Dim objApp As New MapPoint.Application
  Dim objMap As MapPoint.Map
 
  'Set up application
  Set objMap = objApp.ActiveMap
  objApp.Visible = True
  objApp.UserControl = True
 
  'Select an area on the map, then zoom in to this selected area
  objMap.SelectedArea.SelectArea 20, 40, 100, 150
  objMap.SelectedArea.Location.GoTo
 
  End Sub