Revit 2022 API |
DatumPlane..::..IsLeaderValid Method |
DatumPlane Class See Also |
Identifies if the leader valid or not for this DatumPlane. This method does not apply to Reference planes (which do not support leaders).
Namespace: Autodesk.Revit.DB
Assembly: RevitAPI (in RevitAPI.dll) Version: 22.0.0.0 (22.1.0.0)
Since:
2016
Syntax
C# |
---|
public bool IsLeaderValid( DatumEnds datumEnd, View view, Leader leader ) |
Visual Basic |
---|
Public Function IsLeaderValid ( _ datumEnd As DatumEnds, _ view As View, _ leader As Leader _ ) As Boolean |
Visual C++ |
---|
public: bool IsLeaderValid( DatumEnds datumEnd, View^ view, Leader^ leader ) |
Parameters
- datumEnd
- Type: Autodesk.Revit.DB..::..DatumEnds
The end of the datum plane.
- view
- Type: Autodesk.Revit.DB..::..View
The view on which the DatumPlane shows.
- leader
- Type: Autodesk.Revit.DB..::..Leader
The Leader for setting the datum plane.
Return Value
True if the leader is valid for set leader, false otherwise.
Remarks
If the view or leader is null, it will throw ArgumentNullException;
A valid leader meets the following conditions:
- The leader's End, Elbow and Anchor should lie in the View's plane
- The End of the leader should be on the datum plane's curve(s)
- The Elbow of the leader should be between the End and Anchor
Exceptions
Exception | Condition |
---|---|
Autodesk.Revit.Exceptions..::..ArgumentNullException | A non-optional argument was null |
Autodesk.Revit.Exceptions..::..ArgumentOutOfRangeException | A value passed for an enumeration argument is not a member of that enumeration |
Autodesk.Revit.Exceptions..::..InvalidOperationException | This datum plane has no leaders. -or- The DatumPlane should not have a leader. |