BreakCurve Method


Breaks the duct curve into two parts at the given position.

Namespace: Autodesk.Revit.DB.Mechanical
Assembly: RevitAPI (in RevitAPI.dll) Version: 17.0.0.0 (17.0.484.0)
Since: 2017

Syntax

C#
public static ElementId BreakCurve(
	Document document,
	ElementId ductId,
	XYZ ptBreak
)
Visual Basic
Public Shared Function BreakCurve ( _
	document As Document, _
	ductId As ElementId, _
	ptBreak As XYZ _
) As ElementId
Visual C++
public:
static ElementId^ BreakCurve(
	Document^ document, 
	ElementId^ ductId, 
	XYZ^ ptBreak
)

Parameters

document
Type: Autodesk.Revit.DB Document
The document.
ductId
Type: Autodesk.Revit.DB ElementId
The element id of the duct curve to break.
ptBreak
Type: Autodesk.Revit.DB XYZ
The break point on the duct curve.

Return Value

The new duct curve element id if successful otherwise if a failure occurred an invalidElementId is returned.

Remarks

This method is not applicable for breaking the flex duct.

Exceptions

Exception Condition
Autodesk.Revit.Exceptions ArgumentException "The element is neither a duct nor a duct placeholder." -or- "The given point is not on the duct curve."
Autodesk.Revit.Exceptions ArgumentNullException A non-optional argument was NULL

See Also