MultiSegmentGrid.Create
Method
Description:
Create a MultiSegmentGrid element from the specified curve loop.
Create a MultiSegmentGrid element from the specified curve loop.
Remarks:
For each curve in the curve loop, a corresponding Grid will be created.
For each curve in the curve loop, a corresponding Grid will be created.
Syntax
Parameters
| Parameter | Type | Description |
|---|---|---|
| document | Document | The document in which to create the MultiSegmentGrid. |
| typeId | ElementId | Element id of a GridType element. |
| curveLoop | CurveLoop | An open curve loop consisting of lines and arcs. |
| sketchPlaneId | ElementId | Element id of a SketchPlane for the curves elements that will be created from the curveLoop. |
Return Value
| Type | Description |
|---|---|
| ElementId | The element id of the new MultiSegmentGrid element. |
Exceptions
| Exception | Condition |
|---|---|
| ArgumentException | The element id should refer to a valid horizontal SketchPlane. -or- The element id should refer to a GridType element. -or- The curve loop should be an open loop consisting of lines and arcs. |
| 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. |