# Selecting all tag categories

**URL:** <https://forum.dynamobim.com/t/selecting-all-tag-categories/8606>\
**Category:** Revit\
**Created:** [January 4, 2017, 1:16pm UTC](https://forum.dynamobim.com/t/selecting-all-tag-categories/8606 "2017-01-04T13:16:31Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![l.rozendaal](https://avatars.discourse-cdn.com/v4/letter/l/5e9695/32.png) [@l.rozendaal](https://forum.dynamobim.com/u/l.rozendaal)\
**Post date:** [January 4, 2017, 1:16pm UTC](https://forum.dynamobim.com/t/selecting-all-tag-categories/8606/1 "2017-01-04T13:16:31Z")

</div>

Is there an easy way for selecting all tag categories? I need them as input for “Element in view by category” node.

First I wanted to select them 1 by 1 and make a list. (see pic.) but I found out there are 101 different tag categories \>.\<

 ![](https://us1.discourse-cdn.com/flex022/uploads/dynamobim/original/3X/6/5/651b3c928ff7a9bce501a58631699e8980541c38.PNG)

so I tried the following:

 ![](https://us1.discourse-cdn.com/flex022/uploads/dynamobim/original/3X/d/f/df0a151e688513e36818796875a33fa66048c78d.PNG)

But the “Element in view by category” won’t take that list as input.

Any1 has a smart idea?

thanks in advance!

---

<div class="post-metadata">

**Author:** ![Yna\_Db](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/yna_db/32/30641_2.png) [@Yna\_Db](https://forum.dynamobim.com/u/Yna_Db)\
**Post date:** [January 4, 2017, 1:42pm UTC](https://forum.dynamobim.com/t/selecting-all-tag-categories/8606/2 "2017-01-04T13:42:25Z")

</div>

There is a node called _Collect All Tags in Project_ in _Bakery_. You can open it (by double-clicking on it) to see how it’s build…

---

<div class="post-metadata">

**Author:** ![T\_Pover](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/t_pover/32/19147_2.png) [@T\_Pover](https://forum.dynamobim.com/u/T_Pover)\
**Post date:** [January 4, 2017, 9:26pm UTC](https://forum.dynamobim.com/t/selecting-all-tag-categories/8606/3 "2017-01-04T21:26:29Z")

</div>

Put this in a python code block and put it between your nodes like in the picture and it should work:

```
import clr
clr.AddReference('RevitAPI')
from Autodesk.Revit.DB import *

clr.AddReference("RevitNodes")
import Revit
clr.ImportExtensions(Revit.Elements)
clr.ImportExtensions(Revit.GeometryConversion)

clr.AddReference("RevitServices")
import RevitServices
from RevitServices.Persistence import DocumentManager

doc = DocumentManager.Instance.CurrentDBDocument
categories = doc.Settings.Categories

cats = IN[0]
listout = []

for cat in cats:
	tempcat = categories.get_Item(cat)
	listout.append(tempcat)
		

OUT = listout

```

 ![](https://us1.discourse-cdn.com/flex022/uploads/dynamobim/original/3X/0/d/0d6c9b7751aabaad1292d10c6dde8fc6476fd7e5.png)

---

<div class="post-metadata">

**Author:** ![l.rozendaal](https://avatars.discourse-cdn.com/v4/letter/l/5e9695/32.png) [@l.rozendaal](https://forum.dynamobim.com/u/l.rozendaal)\
**Post date:** [January 5, 2017, 6:55am UTC](https://forum.dynamobim.com/t/selecting-all-tag-categories/8606/4 "2017-01-05T06:55:51Z")

</div>

Thank you 👍

---

<div class="post-metadata">

**Author:** ![Koh](https://avatars.discourse-cdn.com/v4/letter/k/f0a364/32.png) [@Koh](https://forum.dynamobim.com/u/Koh)\
**Post date:** [August 20, 2020, 12:58am UTC](https://forum.dynamobim.com/t/selecting-all-tag-categories/8606/5 "2020-08-20T00:58:29Z")

</div>

How can I get the below node?  
“Docuent.BuiltInCategories” “Manage.RemoveNulls” “Elements in view by category”
