Packing Lots of Views onto Lots of Sheets

Working with Sheet.ByNameNumberAndViews and if I feed the node more views than will fit on a single sheet the node stops. I’m starting to work out how we might let Dynamo work through a list of views, packing them onto new sheets until it runs out of views.

I think I’m on the right track but I’m missing something. Any help?

Packing Views on Sheets.dyn (19.4 KB)

Let’s clean this up a bit…

Parent DYN

This is straight forward. Just feeding the custom DYF the same stuff you normally feed the Sheet.ByNameNumberTitleBlockAndViews node. The stuff behind the custom node is to move the viewports later. I’ll also need to swap out a new titleblock so somehow I need to get a list of sheets from the output of the custom node.

Custom DYF

Here I start by feeding the Sheet.ByNameNumberTitleBlockAndViews node the information from above. I know it will give a null after the node since I have more views than will fit on a single sheet. I wait for it with the Passthrough node and then pass the sheet number on to figure out how many views we just placed and drop that many items off the list of views. I’m also calculating the next sheet number in the sequence. I’m not really sure I need this last bit as I think the Sheet.ByNameNumberTitleBlockAndViews node will manage this automatically. The last bit of the custom node is, I assume, where the problem lies; I count the number of views that we start with and compare that count to the number of views placed. If they’re equal the DYF should stop (the “NOPE” was just telling me when it didn’t work - I assume I would replace this with a list of sheets or strings of sheet numbers), if they’re not equal the DYF should loop.

Does that make sense? Where am I going wrong? Currently, even if I feed it just 6 views I end up with hundreds of sheets. The first 2 look fine but then the word “null” gets appended. Several hundred sheets later I get a few more sheets named “null”, and “nullnull” and only 4 of the views get placed.


Can I get a what-what?! Can I get a bump-bump?!

Hello, I would really be interested in this issue but unfortunately I don’t have much time these days. However, to make sure to get an answer, I would strongly recommend to reach the forum experts directly with the @ tool.
See this post for instance:

Yeah, I could but I think that misses the point of the forum. They’ll help if they can. If not then it sits on the back burner to be revisited later. Maybe some time will break the solution free.

Let’s change the question a bit… how do you create a recursive/while loop that repeats a series of actions based not on a predefined number of steps but on the outcome of each preceding iteration?

The Sheet.ByNameNumberTitleBlockAndViews node will place multiple views on multiple sheets if you feed it a list of lists for each set of views/sheets. But if you don’t know yet how many views will/might fit on a sheet it’s less helpful.

If I take this set of grouped nodes, and place it end to end, wiring up the output of the left to the corresponding inputs on the right, the whole shebang will cycle through an ever diminishing view list, packing views onto new sheets until the list is empty or the graph runs itself out. Surely, I think, there must be a way to create a node that loops itself.

(the Next Number in String node is custom that I just published - CheapWine - it parses a sheet number as a string and increases the value by one)

The whole shebang working its way through a short list.

@Greg_McDowell, if I understood your intent here, it was to place multiple views on sheets dynamically (like filling up a detail sheet with different sized viewports). Is that right? If yes, did you happen to have any luck figuring this out?

the last image in the previous post was my final solution IIR but it doesn’t open for viewing though the image above that does – don’t know why

one of these (or both) might be what you’re looking for – it never went anywhere at my previous firms and i’ve not introduced it yet at this one so i have no idea what shape it’s in

good luck!

View Packing_ Step 1.dyn (46.0 KB) View Packing_ Step 2.dyn (26.0 KB)