How can I break a connection in Dynamo?

Hi everyone! I am a beginner in Revit and Dynamo. I want to break every connection in a model but I cant find a break command/node in Dynamo. What should I do to separate a connection in Dynamo?

Any pointers are much appreciated!

Break Button:

You can do it via a python node and the api:

This code above is in C# so you have to translate it yourself in python, but the main thing is that you can figure out which part of the api is used to solve your problem.

From here you can start:

Change the python code to allow only the selection of connections and after you selected you get the element id of the connection which can then be deleted via doc.Delete(elementID)

Edit: Another way is to select only the connections is to use the data-shapes package:

1 Like

Thank you for taking the time to reply. So I did code a way to select all the StructuralConnections in a selection. The problem is that if I try to delete it, It will delete the entire model. So with the Break command in Revit, (from my assumption) it basically separated the models from each other like so:

Pre-Break:

Post-Break:


Not sure if this has been exposed in the API, and if it has it may not be doable in all versions. It will almost certainly require some Python code or a zero touch node as I am not aware of any existing nodes to do this.

Any chance you can post a link to a model with one unbroken and one broken connection for testing?

1 Like

Thanks for the post!
Unfortunately I cannot send my project as it’s company property. I don’t dabble with Revit as much but I think it can be replicated by creating a connection between 2 steels an selecting it to break it. I’ve tried all day to find a solution but nothing. I couldn’t find it in the API either so I guess I’m out of luck.