Create Method


Creates a new instance of an Angular Dimension element within the project.

Namespace: Autodesk.Revit.DB
Assembly: RevitAPI (in RevitAPI.dll) Version: 24.0.0.0 (24.0.0.0)
Since:  2017

Syntax

C#
public static AngularDimension Create(
	Document document,
	View dbView,
	Arc arc,
	IList<Reference> references,
	DimensionType dimensionStyle
)
Visual Basic
Public Shared Function Create ( _
	document As Document, _
	dbView As View, _
	arc As Arc, _
	references As IList(Of Reference), _
	dimensionStyle As DimensionType _
) As AngularDimension
Visual C++
public:
static AngularDimension^ Create(
	Document^ document, 
	View^ dbView, 
	Arc^ arc, 
	IList<Reference^>^ references, 
	DimensionType^ dimensionStyle
)

Parameters

document
Type: Autodesk.Revit.DBDocument
The document where new Angular Dimension is created.
dbView
Type: Autodesk.Revit.DBView
The view in which the Angular Dimension will appear.
arc
Type: Autodesk.Revit.DBArc
Arc for the Angular Dimension.
references
Type: System.Collections.GenericIListReference
The references which the Angular Dimension will witness.
dimensionStyle
Type: Autodesk.Revit.DBDimensionType
Dimension Style.

Return Value

The newly created Angular Dimension instance, or a null reference (Nothing in Visual Basic) if the operation fails.

Exceptions

ExceptionCondition
Autodesk.Revit.ExceptionsArgumentException References should be: at least two, non parallel and rays of the arc passed.
Autodesk.Revit.ExceptionsArgumentNullException A non-optional argument was null
Autodesk.Revit.ExceptionsModificationForbiddenException 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.
Autodesk.Revit.ExceptionsModificationOutsideTransactionException The document has no open transaction.

See Also

ArchiLabs

Stop fighting Revit automation.

Build repeatable BIM design and documentation workflows with scripts, data, and AI in one place, without wrestling brittle one-off automations.

Try ArchiLabs →