Looping a part of a script with different inputs

i am making a script to create sheets with views from area’s for a multiple story appartement building (i use the lunchbox area element collector). now the script is succesfull if i run it with 1 area (1 appartement). but with multiple areas it fails. so i think i have to loop the script from collecting the first area and make the sheet and complete the procces, and then take area 2 and do it again.

i dont know if it is but is it posible to do this? ( i marked the part in the picture red what i think has to be looped)

Thankyou.

Can’t read your screenshot as it wasn’t zoomed in enough.

However I can say that there is no need to loop. You want to use this on a list of areas, so feed a list of areas.

After changing the initial area input to a method that grabs the list of areas wire it into your script. Trace the data flow and start adjusting lacing and levels along the graph you go so that the data doesn’t reduce the error set to a single level.

Thanks for the reply’s!

to make it more clear, here is my script

create views from areas.dyn (101.3 KB)

I don’t know what exactly is going on in your script. But if you simply give 3 lists for the element.set parameterbyname node Dynamo will just do fine. You might also give a list of lists, or a list of lists of lists.

Dynamo is very flexible when it comes to that.

1 Like