AreaReinforcement using dynamo

Hi,
Need some help making a script. I’m a little new to dynamo. I made a script that places an areareinforcementsystem (using the Bim4struc package). Like in revit. In Revit you can remove the system en keep the rebars

Question:
How can I remove reinforcementsystem using Dynamo and keep all top and bottom rebars?
Maby with python or…?

My script:

Thnx in advance

Yes, sure it is possible, but you have to create a python node with this method:

http://www.revitapidocs.com/2017/497ef418-b0cc-e0a2-34d1-67ef49274801.htm

import clr

clr.AddReference('RevitAPI')
from Autodesk.Revit.DB import *
from Autodesk.Revit.DB.Structure import *

clr.AddReference('RevitNodes')
import Revit
clr.ImportExtensions(Revit.GeometryConversion)
clr.ImportExtensions(Revit.Elements)

clr.AddReference('RevitServices')
import RevitServices
from RevitServices.Persistence import DocumentManager
from RevitServices.Transactions import TransactionManager

doc = DocumentManager.Instance.CurrentDBDocument

#Preparing input from dynamo to revit
if isinstance(IN[0], list):
	elements = UnwrapElement(IN[0])
else:
	elements = [UnwrapElement(IN[0])]


#Do some action in a Transaction
TransactionManager.Instance.EnsureInTransaction(doc)
for e in elements:
	AreaReinforcement.RemoveAreaReinforcementSystem(doc,e)
TransactionManager.Instance.TransactionTaskDone()

OUT = 0
1 Like

Thanks for your reply.
I’ll give it a try

Einar i’ve tested your script and it works. Thnx again

Hi!

Could you please say if it’s possible to get the id of these rebar sets, I need to change some of their parameters after removing the Area reinforcement system, but I don’t know how?

Thank you in advance