AddLeader Method


Adds a default Leader for the indicated end of the datum plane. This method does not apply to Reference planes (which do not support leaders).

Namespace: Autodesk.Revit.DB
Assembly: RevitAPI (in RevitAPI.dll) Version: 16.0.0.0 (16.0.0.0)
Since: 2016

Syntax

C#
public Leader AddLeader(
	DatumEnds datumEnd,
	View view
)
Visual Basic
Public Function AddLeader ( _
	datumEnd As DatumEnds, _
	view As View _
) As Leader
Visual C++
public:
Leader^ AddLeader(
	DatumEnds datumEnd, 
	View^ view
)

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.

Return Value

The Leader of the datum plane. Null will return if the view is null.

Remarks

The leader can be added only to ends where the bubble is set to be shown and does not have a leader applied.

Exceptions

Exception Condition
Autodesk.Revit.Exceptions ArgumentException The datum plane cannot be visible in the view. -or- The bubble is not visible at the datumEnd of the datum plane.
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 already has a leader applied.

See Also