Hooks🪝 : automatically change active workset to match the workset of the group that is being edited

Yesterday I have had this idea to create a hook that changes the active workset to match the workset of the group that is being edited, and change it back when the group is finished. As far as I know there are no EventArgs that listen wether a group is being edited or finished. Anyone a good idea on how to go about this?

Edit: I think we can all agree it shouldn’t be possible in the first place to to create an element in a group that has a different workset than the group itself.

1 Like

I think that might be possible, to have a custom trigger using the idling event, and checking if there is a ribbon panel called “Edit Group”. In theory. I have never tried it, so its up to you to figure it out. Be very careful about what you put in your Idling event, because you can easily make your Revit unresponsive.

2 Likes