AddLoop Method


BRep Builder Add Loop Method

Creates an empty loop in a given face of the geometry being built. Other BRepBuilder methods are used to add co-edges to the loop.

Namespace: Autodesk.Revit.DB
Assembly: RevitAPI (in RevitAPI.dll) Version: 25.0.0.0 (25.0.0.0)
Syntax
public BRepBuilderGeometryId AddLoop(
	BRepBuilderGeometryId faceId
)

Parameters

faceId BRepBuilderGeometryId
Id of the face to which the loop should be added. faceId was returned by a call to AddFace().

Return Value

BRepBuilderGeometryId
An id that can be used to identify the loop while the BRepBuilder is actively building geometry (e.g., to add co-edges to the loop).
Exceptions
Exception Condition
ArgumentException The supplied face id doesn't correspond to a face stored in this BRepBuilder object. -or- FinishFace() has already been called on faceId. -or- Please finish the previous loop by calling FinishLoop() before adding a new one.
ArgumentNullException A non-optional argument was null
InvalidOperationException This BRepBuilder object isn't accepting new data, either because it has already been used to build geometry, or because of an error. Consult the State property of the BRepBuilder object for more details.
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 →