Whelp, that helped it to run past line 4 but now its giving me a different error message on each of them. I have pasted the two node text bodies below if that helps. I am not sure what the errors mean. Error message images are here:
Make Sheets
import clr
clr.AddReference(āRevitAPIā)
from Autodesk.Revit.DB import *
clr.AddReference(āRevitNodesā)
import Revit
clr.ImportExtensions(Revit.Elements)
clr.AddReference(āRevitServicesā)
import RevitServices
from RevitServices.Persistence import DocumentManager
from RevitServices.Transactions import TransactionManager
doc = DocumentManager.Instance.CurrentDBDocument
sheets = IN[0]
views = IN[1]
x = IN[2]
y = IN[3]
viewsplaced = list()
TransactionManager.Instance.EnsureInTransaction(doc) # you need an active transaction as you will create elements
for Number in range(len(sheets)):
sheet = UnwrapElement(sheets[number])
view = UnwrapElement(views[number])
Viewport.Create(doc,sheet.Id,view.Id,XYZ(x,y,0))
Viewsplaced.append(view.ToDSType(False))
TransactionManager.Instance.TransactionTaskDone()
OUT = viewsplaced
Make Sheets
import clr
clr.AddReference(āRevitAPIā)
from Autodesk.Revit.DB import *
clr.AddReference(āRevitNodesā)
import Revit
clr.ImportExtensions(Revit.Elements)
clr.AddReference(āRevitServicesā)
import RevitServices
from RevitServices.Persistence import DocumentManager
from RevitServices.Transactions import TransactionManager
doc = DocumentManager.Instance.CurrentDBDocument
sheets = IN[0]
views = IN[1]
x = IN[2]
y = IN[3]
viewsplaced = list()
TransactionManager.Instance.EnsureInTransaction(doc) # you need an active transaction as you will create elements
for Number in range(len(sheets)):
sheet = UnwrapElement(sheets[number])
view = UnwrapElement(views[number])
Viewport.Create(doc,sheet.Id,view.Id,XYZ(x,y,0))
Viewsplaced.append(view.ToDSType(False))
TransactionManager.Instance.TransactionTaskDone()
OUT = viewsplaced