How can I get Bounding Box or WorkPlane from Section View?

I know there is a node(or python) for getting Section View from BoundingBox,
Then, how can I get BoundingBox or Workplane from Section Vew?
I searched everywhere, but I can’t find any clue.

# s = your_selected_section
# av = active view
s.get_BoundingBox(av)
s.Min
s.Max

Thanks for the answer.
But I’m not sure how to use what you wrote.(it doesn’t seem like for Python…)
May I ask you to write full code of usage example?
Thanks in advance.

Hello @Hyunu_Kim
here an example

import clr
import sys
import System
clr.AddReference('ProtoGeometry')
from Autodesk.DesignScript.Geometry import *
import Autodesk.DesignScript.Geometry as DS

#import Revit API
clr.AddReference('RevitAPI')
import Autodesk
from Autodesk.Revit.DB import *
import Autodesk.Revit.DB as DB

clr.AddReference('RevitNodes')
import Revit
clr.ImportExtensions(Revit.GeometryConversion)

view = UnwrapElement(IN[0])
cpbbx = view.CropBox
tfBBx = cpbbx.Transform 
newBBx = BoundingBoxXYZ()
newBBx.Min = tfBBx.OfPoint(cpbbx.Min)
newBBx.Max = tfBBx.OfPoint(cpbbx.Max)
ddsBBx = DS.BoundingBox.ByCorners(newBBx.Min.ToPoint(), newBBx.Max.ToPoint())

OUT = ddsBBx
1 Like

Oh ,Thanks poupin. I’ll try with it. :slight_smile: