When right click a stacked wall, click the BREAK UP button in the menu, the stacked wall will be breaked up.
It will be changed into two independent walls. Now, I want to do it with batch operation.
Is there any corresponding API about BREAKING UP a Stacked Wall?
Thank you !
Solved! Go to Solution.
Solved by nagyidaipeter. Go to Solution.
Maybe you can try to do it by getting the command id and executing it.
I'd be interested in knowing how you got it to work -
var id = RevitCommandId.LookupCommandId("ID_BREAK_UP_WALL");
uiapp.PostCommand(id); throws an argument exception as it's not postable.
However, after giving up on this route, I stumbled across a simple solution that seems to work:
ElementTransformUtils.CopyElements(doc, wall.GetStackedWallMemberIds(), XYZ.Zero);
- you'll need to delete the original wall to avoid an overlapping elements warning.
Peter