Door Number by Room Number

Hi to all of you, I am writing to you because I am having difficulty setting a parameter on a family (in this case, door), which is fundamental for my degree thesis, in which I want to develop the Facility Management theme and to do so I am using a tool called COBie. To understand how it works, I’m seeing video tutorials on the internet, because I can’t find adequate literature to talk about it. The videos shows an example project showing that the doors have the same identification number as the room they access (as you can see in the photo that I have attached).

On Autodesk forum a user suggested me to use dynamo (I’ve never used it) and linked me a video ( but when I set the data that are in the video therewas a warning that say " Error: Room is a name of class and can’t be used as variable" un nome di classe e non può essere utilizzato come variabile." I tried to write commands in Italian, because I’m using revit in Italian and there’s another type of warning (yellow in this case) (please see the attached n. 2) and it says "Warning: Get. Operation ValueAtIndex failed. Index not included in the range. Non-negative value required and smaller than collection size.
Parameter name: index.
I don’t understand where is the problem. How can I do?
As I said before, this thing should also be reproduced for other families, including windows and furniture (being a school I would have a catalogue of the elements identified by floor or even by class). I hope you can understand what I want to say. Thanks everybody for the help.

Try this:
If you create a new Door schedule and you click on Doors here (see below)
you can see From Room and To Room. So the information is there. You now need to create a DoorTag that includes this value.

I’ve already created a Door schedule with From Room and To Room. I activated Room calculation point but when I create the room tag there’s no parameter that allow me to set this information. How can I set the information on Dynamo? It’s the first time for me the use of it and I don’t know what I have to insert into. I’ve already tried several combinations found on the forum but they don’t never work. Could be the language the problem?

create a new shared project parameter, name it To Room and set it to the Doors category (so all doors get this new parameter) then try this

1 Like

Great documentation on this can be found on @Konrad_K_Sobon’s blog, here:


Ciao Cristina,

I am curious how you plan to deal with rooms that have multiple doors and windows. I suggest you try using the room number plus a letter for each different door, window or element. However, that will limit you to 20 or so elements, one for each letter of the alphabet. Then you would need to start AA, AB, AC, etc. up to ZZ which should be plenty enough.



Dear Marcel, I can’t find “Get.NestedFamily”. Do I have download some pack to get it?

Thank you so much Jacob. I’ve followed the guide, downloaded the packs written in the text and downloaded the file DYN but I’ve 2 red and 1 yellow errors. Unfortunately I can’t resolve them because is the first work where I use Dynamo. Can you suggest me something?

Ciao Emmanuel, for that rooms that have multiple doors and windows I would set parameter that it’s allowing me to have the follow configuration: 1D01_A, 1D02_B,…
I would have this configuration especially for the forniture because I want to apply the FM on them too.

1 Like

That exact example is quite old, so there have been some name changes alonn the way which will keep the old version from opening correctly. This explains the red nodes.

However if you have the latest Dynamo for Revit and the matching Archilab package I am sure you could find the related nodes in the library and get it running again.

I recommend you review the Dynamo Primer, do every exercise and skip nothing as it’s not the results that are important, but the concepts which are well documented there. Once you do that building or repairing the example in the Archilab blog will be rather easy. If you’re still stuck after that then post more specifics, including a good image export of the graph and we can help you fix the unresolved nodes (red) and warnings (yellow) that way.

1 Like

Hello @cristina.vagnozzi maybe you can skip the Get.NestedFamily node.
I found the picture of the graph somewhere and i copied it in my answer.

I’ve tried the solution proposed by Marcel without the Get.NestedFamily and it doesn’t work. This is the image of the graph

I’ve already check the Room calculation Point and set From and To Room. I put the tag on the doors but it doesn’t work.

I’m not an expert but this is the simplest method to throw the room number value to door mark in this case, though this does not give the sequence number of doors if you have multiple doors in a room.

You need to have the rhythm package for the Element.Room node

1 Like

This may also be of assistance

1 Like

Thank you for your suggestion. I’ve donwloaded the rhythm package but there’s no the Element.Room node. Is there another package where I can find it?

see attached fileElement.Room.dyf (3.7 KB)

1 Like

I tried to use the guide but there aren’t those elements (Prefix, Mark Seprator and Update, as you can see in attached). Is there another package that I have to get?1

I believe the Prefix & Mark separator’s are just renamed strings & the update node is a boolean

1 Like

I have been working on a similar graph that has the added number based on how many doors have been added to the room. As of right now, the doors are currently numbered based on the order that they were placed within the room. The text within the Python Script node can be found in the first comment on this video (but I believe it originally came from Konrad Sobon.)

Two things I have been struggling with are

  • doors that open to the exterior are tagged with rooms they aren’t associated with
  • if I change a door that swings from room A to room B to swing the opposite way, it doesn’t update when I run the script again

Hi Kaela, I’ve already watched this video but I can’t edit (I can’t delete and paste the text) the python script and I don’t know why. I tried to write all lines on my own but it didn’t work. Is it possibile that the new release don’t allow it?