PlanViewRange
Description:
This class represents the view range of a plan view or a plan region. It records the element ids of the levels which a plane is relative to and the offset of each plane from that level.
This class represents the view range of a plan view or a plan region. It records the element ids of the levels which a plane is relative to and the offset of each plane from that level.
public class PlanViewRange : IDisposable
private ElementId GetViewRangeTopClipPlane(Document doc, View view)
{
ElementId topClipPlane = ElementId.InvalidElementId;
if (view is ViewPlan)
{
ViewPlan viewPlan = view as ViewPlan;
PlanViewRange viewRange = viewPlan.GetViewRange();
topClipPlane = viewRange.GetLevelId(PlanViewPlane.TopClipPlane);
double dOffset = viewRange.GetOffset(PlanViewPlane.TopClipPlane);
if (topClipPlane != ElementId.InvalidElementId)
{
Element levelAbove = doc.GetElement(topClipPlane);
TaskDialog.Show(view.Name, "Top Clip Plane: " + levelAbove.Name + "\r\nTop Offset: " + dOffset + " ft");
}
}
return topClipPlane;
}
| Name | Return Type | Description | Inherited From |
|---|---|---|---|
| Dispose() | None | Releases all resources used by the PlanViewRange | |
| Equals | None | Determines whether the specified object is equal to the current object. (Inherited from Object ) | Object |
| GetHashCode | None | Serves as the default hash function. (Inherited from Object ) | Object |
| GetLevelId(PlanViewPlane) | ElementId | Get the element id of the level for a View Depth plane | |
| GetOffset(PlanViewPlane) | Double | Get the offset value associated with a View Depth plane | |
| GetType | None | Gets the Type of the current instance. (Inherited from Object ) | Object |
| SetLevelId(PlanViewPlane, ElementId) | None | Set the level for a View Depth plane | |
| SetOffset(PlanViewPlane, Double) | None | Set the offset value associated with a View Depth plane | |
| ToString | None | Returns a string that represents the current object. (Inherited from Object ) | Object |
| Name | Return Type | Description | Inherited From |
|---|---|---|---|
| Current | ElementId | View range for the current plane | |
| IsValidObject | Boolean | Specifies whether the .NET object represents a valid Revit entity. | |
| LevelAbove | ElementId | View range for the level above the specified plane | |
| LevelBelow | ElementId | View range for the level below the specified plane | |
| Unlimited | ElementId | View range is unlimited |