Create Method


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

Namespace: Autodesk.Revit.DB
Assembly: RevitAPI (in RevitAPI.dll) Version: 17.0.0.0 (17.0.484.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.DB Document
The document where new Angular Dimension is created.
dbView
Type: Autodesk.Revit.DB View
The view in which the Angular Dimension will appear.
arc
Type: Autodesk.Revit.DB Arc
Arc for the Angular Dimension.
references
Type: System.Collections.Generic IList Reference
The references which the Angular Dimension will witness.
dimensionStyle
Type: Autodesk.Revit.DB DimensionType
Dimension Style.

Return Value

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

Exceptions

Exception Condition
Autodesk.Revit.Exceptions ArgumentException References should be: at least two, non parallel and rays of the arc passed.
Autodesk.Revit.Exceptions ArgumentNullException A non-optional argument was NULL
Autodesk.Revit.Exceptions 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.
Autodesk.Revit.Exceptions ModificationOutsideTransactionException The document has no open transaction.

See Also