PartUtilsDivideParts Method |
Creates divided parts out of parts.
Namespace: Autodesk.Revit.DBAssembly: RevitAPI (in RevitAPI.dll) Version: 25.0.0.0 (25.0.0.0)
Syntaxpublic static PartMaker DivideParts(
Document document,
ICollection<ElementId> elementIdsToDivide,
ICollection<ElementId> intersectingReferenceIds,
IList<Curve> curveArray,
ElementId sketchPlaneId
)
Public Shared Function DivideParts (
document As Document,
elementIdsToDivide As ICollection(Of ElementId),
intersectingReferenceIds As ICollection(Of ElementId),
curveArray As IList(Of Curve),
sketchPlaneId As ElementId
) As PartMaker
public:
static PartMaker^ DivideParts(
Document^ document,
ICollection<ElementId^>^ elementIdsToDivide,
ICollection<ElementId^>^ intersectingReferenceIds,
IList<Curve^>^ curveArray,
ElementId^ sketchPlaneId
)
static member DivideParts :
document : Document *
elementIdsToDivide : ICollection<ElementId> *
intersectingReferenceIds : ICollection<ElementId> *
curveArray : IList<Curve> *
sketchPlaneId : ElementId -> PartMaker
Parameters
- document Document
-
The document containing the parts.
- elementIdsToDivide ICollectionElementId
-
The elements that will be divided.
- intersectingReferenceIds ICollectionElementId
-
Intersecting references that will divide the elements.
- curveArray IListCurve
-
Array of curves that will divide the elements.
- sketchPlaneId ElementId
-
SketchPlane id for the curves that divide the elements.
Return Value
PartMaker
The newly created PartMaker.
if no parts are divided.
ExceptionsException | Condition |
---|
ArgumentException |
One or more element ids was not permitted for dividing parts.
Elements should be parts that are not yet divided and maximum distance from an original has not yet been reached.
-or-
One or more element ids was not permitted as intersecting references.
Intersecting references should be levels, grids, or reference planes.
-or-
The element id should refer to a valid SketchPlane.
-or-
The input curveArray contains at least one helical curve and is not supported for this operation.
-or-
The input curveArray contains at least one NULL pointer and is not supported for this operation.
|
ArgumentNullException |
A non-optional argument was null
|
InvalidOperationException |
The document is in failure mode: an operation has failed,
and Revit requires the user to either cancel the operation
or fix the problem (usually by deleting certain elements).
|
ModificationForbiddenException |
The document is in failure mode: an operation has failed,
and Revit requires the user to either cancel the operation
or fix the problem (usually by deleting certain elements).
-or-
The document is being loaded, or is in the midst of another
sensitive process.
|
ModificationOutsideTransactionException |
The document has no open transaction.
|
See Also