Item property (DataSets)
Returns a DataSet object based on its Name property or position within the specified DataSets collection. Read-only.
Applies to
Collections: DataSets
Syntax
object.Item(Index)
Parameters
Part | Description |
---|---|
object | Required. An expression that returns a DataSets collection. |
Index | Required Variant. The name of the data set, or an integer representing the index number of the data set within the collection. |
Remarks
The Item property is the default property for the DataSets collection.
Example
Sub GetPushpinDataSetName()
Dim objApp As New MapPoint.Application
Dim objMap As MapPoint.Map
'Set up the application
Set objMap = objApp.ActiveMap
objApp.Visible = True
objApp.UserControl = True
'Add a Pushpin to the map
objMap.AddPushpin objMap.FindResults("Seattle, WA")(1)
'Get the Pushpin data set name
MsgBox "Pushpin data set name: " + objMap.DataSets.Item(1).Name
End Sub
Note This sample code is specific for use in MapPoint North America; it is for illustration purposes only.