PartUtils.GetSplittingCurves(Document, ElementId)
Method
Description:
Identifies the curves that were used to create the part.
Identifies the curves that were used to create the part.
Examples
public void GetCurveDividers(Part part)
{
StringBuilder message = new StringBuilder();
// Get curve dividers.
IList<Curve> divisionCurves = PartUtils.GetSplittingCurves(part.Document, part.Id);
if (divisionCurves.Count == 0)
message.AppendLine("Part is not divided.");
else
{
message.AppendLine("The dividers are : ");
if (divisionCurves.Count > 0)
message.AppendLine(divisionCurves.Count.ToString() + " division curves");
}
TaskDialog.Show("Revit", message.ToString());
}
Parameters
Parameter | Type | Description |
---|---|---|
document | Document | The source document of the part. |
partId | ElementId | The part id. |
Return Value
Type | Description |
---|---|
IList | The curves that created the part. Empty if partId is not a Part or Part is not divided. |
Exceptions
Exception | Condition |
---|---|
ArgumentNullException | A non-optional argument was null |