# Change the active workset

**URL:** <https://forum.dynamobim.com/t/change-the-active-workset/45946>\
**Category:** Revit\
**Tags:** revit, dynamo\
**Created:** [January 24, 2020, 9:11pm UTC](https://forum.dynamobim.com/t/change-the-active-workset/45946 "2020-01-24T21:11:30Z")\
**Posts on this page:** 1\
**Showing post:** 4

<div class="post-metadata">

**Author:** ![infeeeee](https://avatars.discourse-cdn.com/v4/letter/i/e480ec/32.png) [@infeeeee](https://forum.dynamobim.com/u/infeeeee)\
**Post date:** [January 25, 2020, 12:42am UTC](https://forum.dynamobim.com/t/change-the-active-workset/45946/4 "2020-01-25T00:42:55Z")

</div>

It’s in the api, so you can do it in python:  
[https://thebuildingcoder.typepad.com/blog/2015/02/revit-2015-r2-and-the-read-write-workset-api.html](https://thebuildingcoder.typepad.com/blog/2015/02/revit-2015-r2-and-the-read-write-workset-api.html)

> **[SetActiveWorksetId Method](https://www.revitapidocs.com/2020/9f11d796-ca5c-93d9-51e1-67cf8da9baf2.htm)**
>
> Online Documentation for Autodesk's Revit API: 2015, 2016, 2017, 2017.1, 2018

Here is a thread about worksets in python, not an answer to your question, but it would be a good start if you are not that familiar with python:

> [@How to rename Worksets?](https://forum.dynamobim.com/t/how-to-rename-worksets/19610):
>
> Hi - I am trying to batch rename Worksets. Admittedly I don’t have much experience with python and am really guessing at the modifications required to rename in batch vs. by single workset. " import clr clr.AddReference(‘RevitAPI’) from Autodesk.Revit.DB import \* clr.AddReference(‘RevitNodes’) import Revit clr.ImportExtensions(Revit.GeometryConversion) clr.ImportExtensions(Revit.Elements) clr.AddReference(‘RevitServices’) import RevitServices from RevitServices.Persistence import Docu…

---

_[View the full topic](https://forum.dynamobim.com/t/change-the-active-workset/45946)._
