Is there a connection API window and wall?

How to get parameter indicating that the wall has a window?
The first thing that comes to mind - it’s x and y coordinates (comparing them)

What is it for?
I do Thermal calculation indoors.
using GetСompoundStruсture I know which walls surrounds the room.
I do not know how to determine whether there is a window in the room)))

What are your thoughts?

Hi, in the Wall class there is a method called FindInserts()


from the Revit SDK: "Gets the ids of the instances inserted into this host object. "

reutrns a List of ElementIds and the arguments are 4 booleans:

addRectOpenings: True if rectangular openings should be included in the return. </span>

includeShadows: True if shadows should be included in the return. </span>

includeEmbeddedWalls: True if embedded walls should be included in the return. </span>

includeSharedEmbeddedInserts: True if shared embedded inserts should be included in the return. </span>


Or you can alternatively check the Id of the wall against the value in FamilyInstance.Host.Id where the family instance is a door/window.


Paolo, thank you, but I don’t know how I can write it on the Python script

How I can get parameter: “from room” ? (screen from revit lookup)

Python shouldn’t have a different way to deal with parameters from C# but in this case it does: something like door.get_FromRoom(phase) should do the trick.

Since rooms are phase dependent you need to specify in the argument which phase are you looking at.



This should clarify.


Good day,

This functionality has already been available for some time in the Clockwork package. The two nodes in question are “Element.Inserts” and “Element.Host”


Paolo, Dimitar thank you!

Paolo please give the text of the script
I try to understand

Paolo your script work only with doors, but not working with windows. I not understand.


I admit it isn’t very robust :slight_smile: now should be better


Paolo, I would like a script file .dyn and file .rvt, please

The RVT file is the one you find in the Revit samples, the Dynamo file is nothing much more than the Python script I’ve attached, I just added a try/except block and an if/else block to the version you already managed to write, look closely.


Paolo, thank you

what could be the problem?

I apologize for persistence


Try to flip the windows on the right and on the bottom side of the room and run again…