Walls from Stacked Wall

Hey All,

This guy has the same issue as me, it didn’t get solved in the API forum…


Seemingly I need to collect the component walls from a stacked wall, so I can get their edges.

Seemingly edges cannot be returned from the solid of a stacked wall.

I can do this with nodes, but would welcome help with doing this in Python?

I’d like the user to be able to drag a box… Seeming this approach returns results both in Dynamo & my Python which do not return the component walls.

@Alban_de_Chasteigner maybe this is of interest to you as well :slight_smile:

test.rvt (1.4 MB) object edge test.dyn (24.9 KB)

Edit: So I think I have to get all walls in view and see if they or their host wall match the selected walls… quite slow :frowning:

Hi @Mark.Ackerley,

Thanks for the notification.
I would use the Get Wall Member node before the Compound Edges References node.
(Unfortunately this API method only returns the wall type and not the wall instances directly.)

1 Like

Very interesting, thanks, I’ll investigate tomorrow!

1 Like

So for posterity, here’s the python…

#if I cast the selection to a list I find it easier to work with
targetWalls = list(targetWalls)

for tWall in targetWalls:
   if tWall.IsStackedWall == True:
        targetWalls.extend(doc.GetElement(sub) for sub in tWall.GetStackedWallMemberIds())
for tWall in targetWalls:
   if tWall.IsStackedWall == True:

OUT = targetWalls

I couldn’t remove the stacked walls without a duplicate loop, I expect a lambda would be the way to do it, but I’ll do that another day! :slight_smile:

Hi Mark,

I made an improvement on the custom node to also return the instances of walls.
This will probably be useful for similar worklows with stacked or curtain walls.

1 Like