This document is archived and information here might be outdated. Recommended version. |
ArcObjects Help for .NET developers > ArcObjects namespaces > Controls > ESRI ArcGIS Controls > Interfaces > IT > ITOCControl2 Interface > ITOCControl2.EnableLayerDragDrop Property (ArcObjects .NET 10.5 SDK) |
Indicates if layers can be dragged and dropped in the control.
[Visual Basic .NET] Public Property EnableLayerDragDrop As Boolean
[C#] public bool EnableLayerDragDrop {get; set;}
[C++]
HRESULT get_EnableLayerDragDrop(
VARIANT_BOOL* newVal
);
[C++]
HRESULT put_EnableLayerDragDrop(
VARIANT_BOOL newVal
);
[C++]
Parameters newVal [out, retval] newVal is a parameter of type VARIANT_BOOL newVal [in] newVal is a parameter of type VARIANT_BOOL
Determines whether layers can be dragged and dropped in the TOCControl. This property if false by default. When EnableLayerDragDrap is true, layers can be dragged and dropped as follows:
By default when dragging and dropping a layer within a map, the layer will be moved within the map to the drop location. To copy the layer, rather than move it press the CTRL key while dragging and dropping.
By default when dragging and dropping a layer between maps, a copy of the layer will be added into the map the layer is dropped into. To move the dragged layer, rather than copy it press the CTRL key while dragging and dropping.
Layers can not be dragged and dropped in the following cases: