I need to get the Level parameters out of Linked Columns. I have been able to get out their Bounding Box, Mark and some other parameters but I really need the Level.
My end-game is to have a Graph which will draw a small floor at the top of the column which contains the same Mark and Level of the Column below it.
I have made a Graph which applies Floors on top of all Columns. But I really need the correct Level information in the Floor as well as the ability to apply the Floors on a given Level only.
WALL RUNDOWN_COLUMNS.dyn (1.9 MB)
The parameter will return an actual level element, but the getParameter node does not recognize the Id because it’s in another document. You could do something similar to this:
Thank you. I will give that a try.
If you need the Level element, you can do something like this:
import clr
clr.AddReference('RevitAPI')
from Autodesk.Revit.DB import *
column = UnwrapElement(IN[0])
param = column.get_Parameter(BuiltInParameter.SCHEDULE_TOP_LEVEL_PARAM)
doc = UnwrapElement(IN[2])
OUT = doc[0].GetElement(param.AsElementId())
Thank you very much, that works. Problem I am having is it’s only working for one element at a time. I’m obviously not very good with Python (yet). There must me a way to define a list of elements instead of just one?
You can use a for loop like this: (untested code)
import clr
clr.AddReference('RevitAPI')
from Autodesk.Revit.DB import *
column = UnwrapElement(IN[0])
doc = UnwrapElement(IN[1])
OUT = []
for column in columns:
param = column.get_Parameter(BuiltInParameter.SCHEDULE_TOP_LEVEL_PARAM)
OUT.append(doc[0].GetElement(param.AsElementId()))
1 Like
Good morning,
I need to copy the Base Level value to a “QC_PISO” parameter, however I have not found the correct way to extract the base level value.