Creates a new MEP Electrical System element from a set of electrical components.
Namespace: Autodesk.Revit.DB.Electrical
Assembly: RevitAPI (in RevitAPI.dll) Version: 24.0.0.0 (24.0.0.0)
Since: 2018
Syntax
C# |
---|
|
Visual Basic |
---|
|
Visual C++ |
---|
|
Parameters
- document
- Type: Autodesk.Revit.DBDocument
The Document.
- electComponents
- Type: System.Collections.GenericIListElementId
The electrical components in this system.
- elecSysType
- Type: Autodesk.Revit.DB.ElectricalElectricalSystemType
The System Type of electrical system.
Return Value
If successful a new MEP Electrical System element within the project, otherwise a null reference (Nothing in Visual Basic).Exceptions
Exception | Condition |
---|---|
Autodesk.Revit.ExceptionsArgumentException | There should be at least one component that can create the specified circuit type |
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.ExceptionsDisabledDisciplineException | None of the following disciplines is enabled: Mechanical Electrical Piping. |