ESRI.ArcGIS.ADF.IMS | |
Remove Method | |
See Also Example |
ESRI.ArcGIS.ADF.IMS.Carto.Layer Namespace > LayerCollection Class : Remove Method |
- layer
- The layer to remove.
Visual Basic (Usage) | Copy Code |
---|---|
|
Parameters
- layer
- The layer to remove.
The following example removes a layer from the map's layer collection using a
reference to the layer. The code assumes an existing MapView object.
C# | Copy Code |
---|---|
// Get the layer collection from a MapView |
Visual Basic | Copy Code |
---|---|
' Get the layer collection from a MapView |
This method removes a layer completely from the layer collection of the
MapView
orDataFrame. Both dynamic and
static layers may be removed. After removal, the layer is not recoverable in the
current MapView, unless a reference is maintained to the deleted layer and it is
re-added (or unless a new MapView is generated from the
MapService).