TemporaryViewModes.IsModeEnabled Method

TemporaryViewModesIsModeEnabled Method

Tests whether a temporary view mode is currently enabled in the associated view.

Namespace: Autodesk.Revit.DB
Assembly: RevitAPI (in RevitAPI.dll) Version: 25.3.0.0 (25.3.0.0)
Syntax
public bool IsModeEnabled(
	TemporaryViewMode mode
)
Public Function IsModeEnabled ( 
	mode As TemporaryViewMode
) As Boolean
public:
bool IsModeEnabled(
	TemporaryViewMode mode
)
member IsModeEnabled : 
        mode : TemporaryViewMode -> bool 

Parameters

mode  TemporaryViewMode
The mode to evaluate

Return Value

Boolean
True if the requested mode is available and enabled in the associated view; False otherwise.
Exceptions
ExceptionCondition
ArgumentOutOfRangeException A value passed for an enumeration argument is not a member of that enumeration
Remarks
Most of temporary modes are enabled in a specific context only. A programmer who wants to use a mode needs to first test whether it is currently available and enabled, or not.
See Also