ArcGIS Pro 2.7 API Reference Guide
SetExpanded Method

ArcGIS.Desktop.Mapping Namespace > Layer Class : SetExpanded Method
Expands.
Sets whether the layer appears expanded i.e. showing legends on the TOC. This method must be called on the MCT. Use QueuedTask.Run
Syntax
public void SetExpanded( 
   bool isExpanded
)
Public Sub SetExpanded( _
   ByVal isExpanded As Boolean _
) 

Parameters

isExpanded
Expands.
Exceptions
ExceptionDescription
This method or property must be called within the lambda passed to QueuedTask.Run.
Requirements

Target Platforms: Windows 10, Windows 8.1

See Also

Reference

Layer Class
Layer Members