GetSegmentByIndex Method


MEPAnalytical Model Data Get Segment By Index Method

Gets the analytical segment at the specified position.

Namespace: Autodesk.Revit.DB.Analysis
Assembly: RevitAPI (in RevitAPI.dll) Version: 25.0.0.0 (25.0.0.0)
Syntax
public MEPAnalyticalSegment GetSegmentByIndex(
	int index
)

Parameters

index Int32
The index where the segment is stored. This index is 0 based.

Return Value

MEPAnalyticalSegment
The returned analytical segment.
Exceptions
Exception Condition
ArgumentOutOfRangeException The index must range from 0 to GetNumberOfSegments()-1.
See Also
ArchiLabs Desktop

Put AI to work inside Revit.

Give Desktop your instructions and project files to build Revit families, update model elements, and create views and schedules. Works directly in Revit and AutoCAD.

Explore Desktop →