Assign name or number of room from linked file to mechanical equipement

Hello all.

Struggling to find a solution. Maybe someone can help.

First thanks to Peter Kompolschek for sharing his work and Konrad Sobon for making script accessible.

With the script you should be able to assign the number of the room of linked Revit file (Architectural building) to the mechanical equipment (or accessories, etc…) in my Revit file (HVAC). I’ve made shared parameter especially for this and it’s assigned to all Mechanical equipment’s.

It works perfectly only for level 0.

Basement, level 1 and level 2 are tagged as they are in level 0. For example. Room in level 1 will get the same number as room just below.

Does anyone have any idea, where to look?

Thank you for the help.
[Room name and number to Equipment.dyn|attachment]

Here is the script isf someone would like to test it…
Room name and number to Equipment.dyn (34.6 KB)

Make sure when you’re sharing screenshots that you have the node preview bubbles pinned. Otherwise we can’t actually see what your graph is doing. Also, be sure to include any code from relevant python nodes in your graph and any error warnings you’re getting. If we don’t have all the same information you have, we can’t really help you.

it doesn’t work.