Creating Multiple Sectioned 3D Views

I’m trying to create a section box of each level and then assign that section box to a 3D view. I currently have a script that will section by one level at a time. All levels would be ideal. The views would already be created, but without the correct section boxes. I just need to know if it’s possible to section multiple 3D views with one script. Can anyone help me out?

This is a simplified version of my script. I’m trying to create two bounding boxes around the first and second floor. Then with the View3D.SetSectionBox node I’m attempting to section Level1 3D by using the bounding box from the first floor and also section Level 2 3D from the second floor bounding box.

Here is the View3D.SetSectionBox Node Opened Up

Here is the python script in the node:
#Copyright© 2017, john pierson

@60secondrevit, http://sixtysecondrevit.com

import clr
clr.AddReference(‘ProtoGeometry’)
from Autodesk.DesignScript.Geometry import *

Import ToDSType(bool) extension method

clr.AddReference(“RevitNodes”)
import Revit
clr.ImportExtensions(Revit.Elements)

Import DocumentManager and TransactionManager

clr.AddReference(“RevitServices”)
import RevitServices
from RevitServices.Persistence import DocumentManager
from RevitServices.Transactions import TransactionManager

from System.Collections.Generic import *

Import RevitAPI

clr.AddReference(“RevitAPI”)
import Autodesk

doc = DocumentManager.Instance.CurrentDBDocument
uiapp = DocumentManager.Instance.CurrentUIApplication
app = uiapp.Application

#The inputs to this node will be stored as a list in the IN variable.
dataEnteringNode = IN

#unwrap all elements to use with API
items = UnwrapElement(IN[0])
box = IN[1]
TransactionManager.Instance.EnsureInTransaction(doc)
#apply lineweight override to elements in an input list
typelist = list()
for i in items:
try:
typelist.append(i.SetSectionBox(box))
except:
typelist.append(list())

“End” the transaction

TransactionManager.Instance.TransactionTaskDone()

#Assign your output to the OUT variable
OUT = typelist

Bump^ I am also Trying to figure this out.

Have you tried making it a nested custom node that deals with the inputs of the list or composing a function?