Close and open worksets using dynamo/python

HI @raysonchan0305, Welcome to Dynamo and the Dynamo Forum! :slight_smile:

There is no way with the OOTB Dynamo nodes that I’m aware of (although, there are most likely packages out there with these features). However, this can be done via the API relatively easily. I have created a graph for this that uses python and the Revit API to reload the chosen link with worksets chosen by the user…

Here is a quick demo…

And the Dynamo Script…
ReloadLinksWithSelectedWorksets.dyn (46.4 KB)

NOTE: Please make sure you read the comments in the graph as you will need to change some of the logic to suit your needs (which revit link you are reloading and which worksets you want to open). Hopefully my explanations are clear enough.

Suggested Improvements: As a rule, I don’t put any third party nodes in any of my graphs that I put on the forum, but a suggestion to make this more complete would be to put DataShapes UI nodes in there so user can run and Select the Revit Link and Worksets via a User Interface (rather than editing the graph directly).

Hope you find this useful and at a later date when you are more confident you can get to grips with the python.

Cheers,
Dan

4 Likes