Sets the underlay base and underlay top to the specified levels.
Namespace: Autodesk.Revit.DB
Assembly: RevitAPI (in RevitAPI.dll) Version: 23.0.0.0 (23.1.0.0)
Since:
2017
Syntax
Visual Basic |
---|
Public Sub SetUnderlayRange ( _
baseLevelId As ElementId, _
topLevelId As ElementId _
) |
Parameters
- baseLevelId
- Type: Autodesk.Revit.DB..::..ElementId
The element id of a level in the project or InvalidElementId. If InvalidElementId,
then the underlay base level is not set and no elements will be displayed as underlay.
- topLevelId
- Type: Autodesk.Revit.DB..::..ElementId
The element id of a level in the project or InvalidElementId. If InvalidElementId,
then the underlay range is unbounded.
Examples
CopyC#
private void ViewUnderlay(ViewPlan planView, ElementId topLevelId, ElementId baseLevelId)
{
if (planView.GetUnderlayOrientation() == UnderlayOrientation.LookingDown)
{
if (planView.GetUnderlayTopLevel() != topLevelId)
{
planView.SetUnderlayRange(baseLevelId, topLevelId);
}
planView.SetUnderlayOrientation(UnderlayOrientation.LookingUp);
}
}
CopyVB.NET
Private Sub ViewUnderlay(planView As ViewPlan, topLevelId As ElementId, baseLevelId As ElementId)
If planView.GetUnderlayOrientation() = UnderlayOrientation.LookingDown Then
If planView.GetUnderlayTopLevel() <> topLevelId Then
planView.SetUnderlayRange(baseLevelId, topLevelId)
End If
planView.SetUnderlayOrientation(UnderlayOrientation.LookingUp)
End If
End Sub
Exceptions
See Also