Dear Dynamo Team,
I have a some insulated pipes in the model. What i am trying to do is to give insulation element as an input and get pipe element of specific insulation as a output. I tried a lot but could not achieved this.
import clr
clr.AddReference("RevitServices")
import RevitServices
from RevitServices.Persistence import DocumentManager
doc = DocumentManager.Instance.CurrentDBDocument
#The inputs to this node will be stored as a list in the IN variables.
if isinstance(IN[0],list):
element = UnwrapElement(IN[0])
else:
element = [UnwrapElement(IN[0])]
listout = []
for x in element:
ownerid = x.HostElementId
listout.append(doc.GetElement(ownerid))
OUT = listout