How to reset Value List component whenever I open/close the program

Hello everyone,

I am writing a GH calculation program in which I use Value Lists as gates to free up the calculation flow. Since these calculations take a lot of time, I am looking for a way to return the Value Lists to the “closed” value whenever I open/close the program.

This avoids the frustration of opening the program after forgetting to close these calculation gates.

For now I am improvising a solution with MetaHopper and for this I need to generate a trigger that fires once, only when I open the program. But I haven’t found a consistent solution yet, because I am new to GH.

Does anyone have any suggestions?

Thanks in advance!

A recent conversation had something similar for a solution…

1 Like

Speaking of that conversation, here’s using the same GHPython logic to set a list of named Value List to a given index when the Grasshopper document opens:


230512_ValueListIndexOnOpen_00.gh (4.3 KB)

2 Likes

Thank you !

Thank you very much, that’s exactly what I was looking for!

1 Like