Which Space on the other side of a wall

Hi everyone!

I would like to get to know which Space is on the other side of a wall (or another Room Bounding Element) of a Space

I created a List of Room Bounding Elements of a Space and a list of surrounding Spaces of a Space. Added together the result is a list of Spaces with surrounding Spaces and Room Bounding Elements:

Now I would like to List which Space is on the other side of a Room Bounding Element (like a Wall). But I don’t know how to make that last step. What do I have to add to this script to get there?

For your information, the output is build up as follows:


And so on for every other Space in the project.

Here you’ll find the script and a Revit model added:
space_element_space.dyn (9.2 KB)
space_element_space.rvt (1.2 MB)

Thanks in advance! Looking forward :slight_smile: