CanElementCutElement Method


Verifies if the cutting element can add a solid cut to the target element.

Namespace: Autodesk.Revit.DB
Assembly: RevitAPI (in RevitAPI.dll) Version: 22.0.0.0 (22.1.0.0)
Since: 2011

Syntax

C#
public static bool CanElementCutElement(
	Element cuttingElement,
	Element cutElement,
	out CutFailureReason reason
)
Visual Basic
Public Shared Function CanElementCutElement ( _
	cuttingElement As Element, _
	cutElement As Element, _
	<OutAttribute> ByRef reason As CutFailureReason _
) As Boolean
Visual C++
public:
static bool CanElementCutElement(
	Element^ cuttingElement, 
	Element^ cutElement, 
	[OutAttribute] CutFailureReason% reason
)

Parameters

cuttingElement
Type: Autodesk.Revit.DB Element
The cutting element.
cutElement
Type: Autodesk.Revit.DB Element
The element to be cut.
reason
Type: Autodesk.Revit.DB CutFailureReason %
The reason that the cutting element cannot add a solid cut to the cut element.

Return Value

True if the cutting element can add a solid cut to the target element, false otherwise.

Exceptions

Exception Condition
Autodesk.Revit.Exceptions ArgumentNullException A non-optional argument was null
Autodesk.Revit.Exceptions ArgumentOutOfRangeException A value passed for an enumeration argument is not a member of that enumeration

See Also

ArchiLabs Desktop

Put AI to work inside Revit.

Give Desktop your instructions and project files to build Revit families, update model elements, and create views and schedules. Works directly in Revit and AutoCAD.

Explore Desktop →