154 Set Active Work Set

Chris McKeown / July 1, 2025

Worksets

~5 min read1,051 words
0 views

Overview

Set Active Work Set reads the Workset assigned to a selected element and immediately makes that Workset the active Workset in Revit. This removes the need to open the Worksets dialog, scroll through the list, and manually switch - one click on an element and the active Workset is updated to match it. The tool only operates on workshared (Worksharing-enabled) projects.

Table of Contents


Key Features

  • Sets the active Workset to match the Workset of a selected element in a single step
  • Works with any element type that carries a Workset assignment (ELEM_PARTITION_PARAM)
  • Reads the element's Workset directly from the Revit built-in parameter - no dialog required
  • Runs a wrapped transaction so any failure is safely rolled back without corrupting the model
  • Immediately operational - no dialog or UI to fill in before the action is applied
  • Detects non-workshared files and exits cleanly with an informational message rather than an error
  • Uses only the first selected element when multiple elements are selected, keeping behaviour predictable

Requirements

  • The Revit project must have Worksharing enabled (i.e. it must be a workshared file)
  • At least one element must be selected before running the tool
  • A valid Bonus Tools licence must be active

Running the Tool

Step 1 - Select an Element

In the Revit canvas, select any element whose Workset you want to make active. Only the first element in the selection is used; additional selections are ignored.


Step 2 - Run the Tool

Launch Set Active Work Set from the Bonus Tools ribbon, or use 115 Search Tools to find it by name.

The tool reads the ELEM_PARTITION_PARAM parameter from the selected element to identify its Workset, then calls SetActiveWorksetId on the document's Workset table.


Step 3 - Confirm the Active Workset

The active Workset shown in the Revit status bar at the bottom of the screen will update immediately to reflect the Workset of the element you selected. No dialog or confirmation prompt appears - the change is applied silently.


Tips and Best Practices

  • Select before running. The tool acts on the current selection at launch time. Make sure you have the correct element selected before clicking the ribbon button.
  • Use it before placing new elements. If you want new elements to land on the same Workset as an existing reference element, select that reference element and run the tool first.
  • Only the first selected element matters. When you have a multi-element selection, the tool reads only the first element's Workset. If in doubt, click a single element to keep the result unambiguous.
  • Check the status bar. After running, glance at the active Workset display in the lower-left of the Revit window to confirm the switch happened as expected.
  • Non-workshared files are handled gracefully. If you accidentally run the tool on a file without Worksharing, it exits with an information message and makes no changes.
  • Pair with Worksharing Display. Use Revit's built-in Worksharing Display mode alongside this tool to visually inspect Workset assignments before and after switching.
  • Undo is supported. The Workset change is wrapped in a named transaction (Set Workset), so you can undo it with the standard Ctrl+Z if needed.

Common Use Cases

Matching the active Workset before placing a linked element - Select a host element on the target Workset, run Set Active Work Set, then place the linked element. It will be assigned to the correct Workset without any manual intervention.

Copying elements to the correct Workset - Before using Copy/Paste or the Move command to place elements on the same Workset as existing content, select a reference element on that Workset and run the tool to prime the active Workset.

Quick Workset auditing during modelling - Click elements at random across the model and run the tool to cycle through the Worksets those elements belong to, verifying that elements are on the expected Worksets as you go.

Setting up Workset-based visibility - When preparing a view with Workset visibility overrides, identify which Workset a key element belongs to by selecting it and running the tool - the active Workset shown in the status bar confirms the assignment without opening the Properties palette.

Recovering from an incorrect Workset assignment - If you notice a newly placed element landed on the wrong Workset, undo the placement, run Set Active Work Set on a correctly placed reference element nearby, then replace the element.


Troubleshooting

"File is not Workshared" message appears The currently open document does not have Worksharing enabled. This tool only works with workshared (central or local) files. Enable Worksharing on the project via the Collaborate tab, or open the correct workshared file.

Active Workset does not change after running Ensure at least one element was selected in the canvas before running the tool. If no elements are selected, the tool has nothing to read and exits without making a change. Select an element and try again.

Tool exits without any visible action and no message This can occur if the selected element does not carry a valid ELEM_PARTITION_PARAM value (for example, certain non-model annotation elements or imported content). Try selecting a different, standard model element such as a wall, floor, or ceiling.

Unexpected Workset is activated When multiple elements are selected, only the first element in the selection set is used. Deselect all and click a single specific element to guarantee the correct Workset is read.

Undo does not revert the Workset change The transaction is named Set Workset in the Revit undo stack - look for that entry rather than the tool name. If the undo stack has been cleared (e.g. after a Save), the change cannot be reverted through undo; manually reset the active Workset via the Worksets dialog.

General error / tool fails silently Check the Bonus Tools output window for a red error message. An unhandled exception in the element read or transaction commit will be caught and logged there. Ensure your Bonus Tools licence is active and that you are running a supported version of Revit.