Pause script for manual interaction in Revit

Can a Dynamo script be paused, to allow for some manual interaction within the Revit program, and then have the script resume?

Hi @JustinStirling,

What exactly are you trying to do? And do you really need the user to interact with revit? Generally I avoid any user interaction unless it is to select an element or to set values for the script in a UI or in graph. Relying on a user to do exactly what you want is a bit of a leap of faith where it could go wrong if the user doesn’t understand what they need to do and do the wrong thing or simply make a mistake.

Having said all that, one potential solution is you could just use a boolean node coupled with an if node in your graph where the true input would be the data you want to pass along and false input be a null (you would place this at the point you want the graph to pause). By default the bool would be set to false so on first run all data would get blocked at the if node and a null passed on (probably throwing a whole load of yellow warnings), then user can do their thing and hit true on the boolean node and run again and the other blocked data can then flow forwards to the rest of the graph. You could also use data-shapes to create a UI to do something similar and might be more obvious to the user what to do as you could add instructions. However, I can think of a few instances this might not be desirable, depends on what you’re trying to do.