GetLinePattern Method (Document, ElementId)


Line Pattern Element Get Line Pattern(Document, Element Id) Method

Gets the LinePattern associated to an element or from a built-in line pattern.

Namespace: Autodesk.Revit.DB
Assembly: RevitAPI (in RevitAPI.dll) Version: 25.0.0.0 (25.0.0.0)
Syntax
public static LinePattern GetLinePattern(
	Document document,
	ElementId elementId
)

Parameters

document Document
The document in which to retrieve the LinePattern.
elementId ElementId
The ElementId of the LinePatternElement or the built-in line pattern id.

Return Value

LinePattern
A copy of LinePattern object. if the ElementId doesn't represent a line pattern element or built-in line pattern. for Solid.
Exceptions
Exception Condition
ArgumentNullException A non-optional argument was null
See Also
ArchiLabs Desktop

Put AI to work inside Revit.

Give Desktop your instructions and project files to build Revit families, update model elements, and create views and schedules. Works directly in Revit and AutoCAD.

Explore Desktop →