ArcGIS Pro 3.4 API Reference Guide
ArcGIS.Desktop.Framework Namespace / State Class / Activate Method
The state string identifier.
Example

In This Topic
    Activate Method (State)
    In This Topic
    Adds the specified state to the state set.
    Syntax
    public void Activate( 
       string stateID
    )
    Public Sub Activate( _
       ByVal stateID As String _
    ) 

    Parameters

    stateID
    The state string identifier.
    Example
    Activate/Deactivate a state - to modify a condition
    // Define the condition in the DAML file based on the state 
    if (activate)
      FrameworkApplication.State.Activate("someState");
    else
      FrameworkApplication.State.Deactivate("someState");
    Requirements

    Target Platforms: Windows 11, Windows 10

    ArcGIS Pro version: 3 or higher.
    See Also