PropertyLineCreate(Document, IListCurveLoop) Method

Creates a new Property element with input CurveLoops and adds it to the document.

Namespace: Autodesk.Revit.DB
Assembly: RevitAPI (in RevitAPI.dll) Version: 27.0.4.0 (27.0.4.0)
Syntax
public static PropertyLine Create(
	Document document,
	IList<CurveLoop> curveLoops
)

Parameters

document  Document
The document to be modified.
curveLoops  IListCurveLoop
The boundary of the PropertyLine.

Return Value

PropertyLine
The new PropertyLine element.
Exceptions
ExceptionCondition
ArgumentException The input curve loops cannot compose a valid boundary, that means: no curve loop is contained in the given collection; these curve loops intersect with each other for some of them; or each curve loop is not planar; or each curve loop is not in a plane parallel to the horizontal(XY) plane.
ArgumentNullException A non-optional argument was null
InvalidOperationException Failed to create new Property line element from input curveloops.
ModificationForbiddenException The document is in failure mode: an operation has failed, and Revit requires the user to either cancel the operation or fix the problem (usually by deleting certain elements). -or- The document is being loaded, or is in the midst of another sensitive process.
ModificationOutsideTransactionException The document has no open transaction.
Remarks
If the input curve loops either: 1) Intersect/overlapped the curve loops within itself. 2) The curves are not in the same plane. 3) Curves include any unbounded circles/ellipses an InvalidOperationException will be thrown. Note that, the curveloop could be open, it is not required to be closed curve loops.
See Also