Sheet Creation via Python Node

Does anyone have a python script that will allow you to create sheets or better yet place holder sheets from a list of “sheet numbers” and “sheet names” ? and Titleblock if Sheets…both current builds only allow for you to create sheets with views packed on them. which is incredible. but i only want placeholder sheets!

thanks!

Hi, I have a node to create a bunch of sheets from list. if used with drafting view, it does what you need. package published today.

DYN create sheets

Thanks Julien,

There is similar built in functionality with the view sheet node. I used a similar workaround with creating drafting views, what i want to do is NOT have extra drafting views in my project if they are just “placeholder sheets”. This is something i’m looking to tackle in the future because i am new to python scripting and want to learn, but i had an immediate need for it.

Cheers!

Someone over at RevitForum uploaded an Add-In that I think should do what you’re looking for. It’s a little old by now so no promises it still works but it should, at least, point you in the right direction.

http://www.revitforum.org/third-party-add-ins-api-r-d/2052-revit-multi-sheet-placeholder-creator.html

Thanks Greg!

Very useful, but not as powerful as having it as a node in Dynamo. What i want to do is have the ability to grab the elements to set other sorting parameters/information after its created.

Cheers!

Looking a bit at the API help file, it appears the code to create sheets is really simple. the picture shows how it works, number input is the amount of sheets to create.

I tried with 1000, took 25 sec on my laptop :slight_smile:

<span style=“line-height: 1.5em;”>Python code is:</span>

Default imports

import clr

clr.AddReference(‘RevitAPI’)
clr.AddReference(‘RevitAPIUI’)
from Autodesk.Revit.DB import *
import Autodesk
import sys

import clr
path = r’C:\Autodesk\Dynamo\Core’
exec_path = r’C:\Autodesk\Dynamo\Core\dll’
sys.path.append(path)
sys.path.append(exec_path)
clr.AddReference(‘LibGNet’)
from Autodesk.LibG import *

#The input to this node will be stored in the IN0…INX variable(s).
doc = IN0
IDs = IN1

for item in IDs:
x = ViewSheet.Create(doc, item)

#Assign your output to the OUT variable
OUT = x

 

DYN placeholder

 

 

looks nice,

I have been trying to do so but I would like to place each view in order first (or in a specific filtered order), one on each sheet/

let’s say I have 20 floor plans and I would like to place them on 20 sheets with a specific titleblock.

I can sort my view list but cannot create a single sheet!

 

Capture

 

look closely at my picture: I use a custom node that iterate through lists. you are using the OOTB node. the custom node is available as a package.

Yes I tried using your node JBE sheet views, but it did not work either

 

I managed to make the python one work but not the other one that seems more intuitive for a non coder like me

the code was not properly pasted in WP, lacking indents

# Default imports
 import clr
 
 clr.AddReference('RevitAPI')
 clr.AddReference('RevitAPIUI')
 from Autodesk.Revit.DB import *
 import Autodesk
 import sys
 
 import clr
 path = r'C:\Autodesk\Dynamo\Core'
 exec_path = r'C:\Autodesk\Dynamo\Core\dll'
 sys.path.append(path)
 sys.path.append(exec_path)
 clr.AddReference('LibGNet')
 from Autodesk.LibG import *
 
 #The input to this node will be stored in the IN0…INX variable(s).
 doc = IN0
 IDs = IN1
 
 for item in IDs:
     x = ViewSheet.Create(doc,item)
 
 #Assign your output to the OUT variable
 OUT = x

the JBE node does not work in 2013 but is fine in 2014

;p

as you can see I make progress on the sheet creation

what i am trying to achieve is to create sheets with all my plans and views one after the other with the titleblock

I can do the view list but I have no clue on how to pick each view instance one after the other and feed it to the sheet view creator. The first one works…

 

make sheets

Julien,

There is no way to set custom sheet numbers or sheet names. It also doesn’t output a list of sheet elements to the apply more functions to…Thanks for this great script, but i like all the functionality of the OOTB Node without adding views to the sheets!

Is there a way to add inputs for a list of Sheet Names and Sheet Numbers? or at least get the output to be a list of created sheets, to which i can modify after? what im actually doing is running the script from an imported excel file, since i want my consultants to take the responsibility for their drawing list!

Thanks!

Here’s a node that lets you create placeholder sheets - up in the package manager now.

placeholdersheets

Wow Andreas,

Brilliant as usual! thanks

I used this node in conjunction with some Excel Data import functionality and i was able to build placeholder sheets for almost 200 consultants sheets at once, along with setting some sorting values afterwards!! *****

Import Sheet Data

up

 

the node still only output a 0 List and a 1 List for the views that are to be on the sheets

is there a way to place in sequence titbleblocks and views (one per sheet in sequence) based on a a sheet number or a number list?DYN-2014-SHEETS

thank you Jean_Mark

 

Willian,

What nodes are you using. Sheet Number and Sheet Name they are plunged into the creates placeholder sheet.