Places the part by its connector to a specific position on the straight part at the specified distance from the host part connector.
Namespace: Autodesk.Revit.DBAssembly: RevitAPI (in RevitAPI.dll) Version: 24.0.0.0 (24.0.0.0)
Since: 2016
Syntax
C# |
---|
public static void PlaceAsTap( Document document, Connector tapPartConnector, Connector hostPartConnector, double distance, double axisRotation, double secondaryAxisRotation ) |
Visual Basic |
---|
Public Shared Sub PlaceAsTap ( _ document As Document, _ tapPartConnector As Connector, _ hostPartConnector As Connector, _ distance As Double, _ axisRotation As Double, _ secondaryAxisRotation As Double _ ) |
Visual C++ |
---|
public: static void PlaceAsTap( Document^ document, Connector^ tapPartConnector, Connector^ hostPartConnector, double distance, double axisRotation, double secondaryAxisRotation ) |
Parameters
- document
- Type: Autodesk.Revit.DB..::..Document
The document.
- tapPartConnector
- Type: Autodesk.Revit.DB..::..Connector
The connector of the part to place.
- hostPartConnector
- Type: Autodesk.Revit.DB..::..Connector
The connector of host part.
- distance
- Type: System..::..Double
The distance to host part connector where to place the part.
- axisRotation
- Type: System..::..Double
The axis rotation in radians.
- secondaryAxisRotation
- Type: System..::..Double
The secondary axis rotation in radians.
Remarks
Tap cannot be placed if it is already connected.
Exceptions
Exception | Condition |
---|---|
Autodesk.Revit.Exceptions..::..ArgumentException | It is not a valid part to place as tap. -or- Tap should be placed on straight part. -or- The distance is out of range. -or- For rectangular and oval parts the axis rotation must be a multiple of PI/2. -or- Invalid tap for host's profile type. -or- The fabrication part is connected. |
Autodesk.Revit.Exceptions..::..ArgumentNullException | A non-optional argument was null |
Autodesk.Revit.Exceptions..::..InvalidOperationException | tap is not connected by its primary connector. |
[!:Autodesk::Revit::Exceptions::InvalidOpertationException] | tap does not fit on the host. |