SetLocationPathForStraightRun Method


Set location path for a straight run by giving a line.

Namespace: Autodesk.Revit.DB.Architecture
Assembly: RevitAPI (in RevitAPI.dll) Version: 24.0.0.0 (24.0.0.0)
Since:  2013

Syntax

C#
public static bool SetLocationPathForStraightRun(
	StairsRun stairsRun,
	Line locationPath
)
Visual Basic
Public Shared Function SetLocationPathForStraightRun ( _
	stairsRun As StairsRun, _
	locationPath As Line _
) As Boolean
Visual C++
public:
static bool SetLocationPathForStraightRun(
	StairsRun^ stairsRun, 
	Line^ locationPath
)

Parameters

stairsRun
Type: Autodesk.Revit.DB.ArchitectureStairsRun
The run whose location path will be set.
locationPath
Type: Autodesk.Revit.DBLine
The location path.

Return Value

Indicate if set is success or not.

Exceptions

ExceptionCondition
Autodesk.Revit.ExceptionsArgumentException The input locationPath is not a bound line. -or- The input locationPath is not a valid location path line for straight run. -or- The locationPath is not valid line used as stairs path(probably it's too short).
Autodesk.Revit.ExceptionsArgumentNullException A non-optional argument was null
Autodesk.Revit.ExceptionsInvalidOperationException The stairs element represented by stairsRun is not in an active StairsEditScope. The run cannot be modified.
Autodesk.Revit.ExceptionsRegenerationFailedException The locationPath doesn't satisfy restrictions to generate straight run.

See Also