Gets the items contained by the IMapItemParent.

Namespace:  ESRI.ArcGISExplorer.Mapping

Assembly:  ESRI.ArcGISExplorer (in ESRI.ArcGISExplorer.dll) Version: 2.0.0.1500 (2.0.0.1500)

Syntax

C#
MapItemCollection ChildItems { get; }
Visual Basic (Declaration)
ReadOnly Property ChildItems As MapItemCollection

Field Value

A MapItemCollection populated with items contained by the IMapItemParent.

Remarks

In the context of the Map class, the collection is used to drive the content of the map in the ArcGIS Explorer Application; Add a MapItem, such as a Note, to the Map.ChildItems collection and it will be added to the map in the application.

Folder is another class that implements IMapItemParent is capable of storing any type of map content in the ChildItems property.

There are circumstances where the IMapItemParent.ChildItems property is read-only, and can only contain items of a specific type. For example KmlLayer.ChildItems cannot be added to, and will only every return a collection of constituent KmlNode objects for the KmlLayer in question. The table below indicates all IMapItemParent types that have containment constraints.

PropertyConstraint
KmlLayer.ChildItems Returns a read-only collection of constituent KmlNode objects for the KML layer.
KmlNode.ChildItems Returns a read-only collection of constituent KmlNode objects for the KML feature.
PackageLayer.ChildItems Returns a read-only collection of constituent PackageChildLayer objects for the package layer.
PackageChildLayer.ChildItems Returns a read-only collection of constituent PackageChildLayer objects for the child layer.
ServiceLayer.ChildItems Returns a read-only collection of constituent ServiceChildLayer objects for the service layer.
ServiceChildLayer.ChildItems Returns a read-only collection of constituent ServiceChildLayer objects for the child layer.

Use the CanAdd method to check if a specified MapItem can be added to the MapItemCollection.

The order of the Map.ChildItems or Folder.ChildItems collection dictates the order in which items are presented in the ArcGIS Explorer contents window. By default, items are added to the end of the collection and will display at the bottom of the content hierarchy. If you wish to add items to the top of the hierarchy use the AddFirst method.

See Also