Creates a new analytical connection between two open connectors.
Namespace: Autodesk.Revit.DBAssembly: RevitAPI (in RevitAPI.dll) Version: 21.0.0.0 (21.1.1.109)
Since: 2018
Syntax
C# |
---|
public static MEPAnalyticalConnection Create( Document doc, ElementId typeId, Connector startConnector, Connector endConnector ) |
Visual Basic |
---|
Public Shared Function Create ( _ doc As Document, _ typeId As ElementId, _ startConnector As Connector, _ endConnector As Connector _ ) As MEPAnalyticalConnection |
Visual C++ |
---|
public: static MEPAnalyticalConnection^ Create( Document^ doc, ElementId^ typeId, Connector^ startConnector, Connector^ endConnector ) |
Parameters
- doc
- Type: Autodesk.Revit.DB..::..Document
The document where the new element is created.
- typeId
- Type: Autodesk.Revit.DB..::..ElementId
The type of new analytical connection.
- startConnector
- Type: Autodesk.Revit.DB..::..Connector
The open connector on the equipment side, whose level is inherited by the analytical connection.
- endConnector
- Type: Autodesk.Revit.DB..::..Connector
The open connector on the network.
Return Value
The newly created analytical connection element.
Exceptions
Exception | Condition |
---|---|
Autodesk.Revit.Exceptions..::..ArgumentException | Invalid connection type. -or- The connector does not support analytical connection. |
Autodesk.Revit.Exceptions..::..ArgumentNullException | A non-optional argument was NULL |