Create Method


Creates a new instance of a mechanical system type and adds it to the document.

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

Syntax

C#
public static MechanicalSystemType Create(
	Document ADoc,
	MEPSystemClassification systemClassification,
	string name
)
Visual Basic
Public Shared Function Create ( _
	ADoc As Document, _
	systemClassification As MEPSystemClassification, _
	name As String _
) As MechanicalSystemType
Visual C++
public:
static MechanicalSystemType^ Create(
	Document^ ADoc, 
	MEPSystemClassification systemClassification, 
	String^ name
)

Parameters

ADoc
Type: Autodesk.Revit.DBDocument
The document where the element will be created and added.
systemClassification
Type: Autodesk.Revit.DBMEPSystemClassification
The classification for the mechanical system type to be created
name
Type: SystemString
The name of the mechanical system type to be created.

Return Value

The newly created mechanical system type element.

Exceptions

ExceptionCondition
Autodesk.Revit.ExceptionsArgumentNullException A non-optional argument was null
Autodesk.Revit.ExceptionsArgumentOutOfRangeException A value passed for an enumeration argument is not a member of that enumeration
Autodesk.Revit.ExceptionsArgumentsInconsistentException The system classification is not valid for the domain of this system type.

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 →