StairsLandingCreateSketchedLandingWithSlopeData Method |
Creates a customized landing between two runs by providing the closed boundary curves of the landing, specifying slope type and height.
Namespace: Autodesk.Revit.DB.ArchitectureAssembly: RevitAPI (in RevitAPI.dll) Version: 25.0.0.0 (25.0.0.0)
Syntaxpublic static StairsLanding CreateSketchedLandingWithSlopeData(
Document document,
ElementId stairsId,
IList<SketchedStairsCurveData> curveLoop,
double baseElevation
)
Public Shared Function CreateSketchedLandingWithSlopeData (
document As Document,
stairsId As ElementId,
curveLoop As IList(Of SketchedStairsCurveData),
baseElevation As Double
) As StairsLanding
public:
static StairsLanding^ CreateSketchedLandingWithSlopeData(
Document^ document,
ElementId^ stairsId,
IList<SketchedStairsCurveData^>^ curveLoop,
double baseElevation
)
static member CreateSketchedLandingWithSlopeData :
document : Document *
stairsId : ElementId *
curveLoop : IList<SketchedStairsCurveData> *
baseElevation : float -> StairsLanding
Parameters
- document Document
-
The document that owns the landing.
- stairsId ElementId
-
The stairs that the new sketched landing belongs to.
- curveLoop IListSketchedStairsCurveData
-
The closed boundary curves of the new landing, specifying slope type and height.
- baseElevation Double
-
Base elevation of the new stairs run. The elevation has following restriction:
- The base elevation is relative to the base elevation of the stairs.
- The base elevation will be rounded automatically to a multiple of the riser height.
- The base elevation should be equal to or greater than half of the riser height.
Return Value
StairsLanding
The new sketched landing.
ExceptionsException | Condition |
---|
ArgumentException |
The element stairsId does not exist in the document
-or-
The stairsId is not a valid stairs element.
-or-
The stairs stairsId has no valid landing type.
-or-
The curveLoop is not closed.
The input curveLoop contains at least one curve which is not a bound Line or bound Arc
and is not supported for this operation.
-or-
Failed to create curve element by the curveLoop.
|
ArgumentNullException |
A non-optional argument was null
|
ArgumentOutOfRangeException |
The given value for baseElevation must be no more than 30000 feet in absolute value.
-or-
The baseElevation is less than half of the riser height of the stairs.
|
InvalidOperationException |
The stairs element represented by stairsId is not in an active StairsEditScope.
New components cannot be added to it.
|
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.
|
RegenerationFailedException |
The curveLoop doesn't satisfy restrictions to generate sketched landing.
|
Remarks
The new stairs landing and the document will be regenerated.
This should be run from within an open transaction.
See Also