I have just started creating my own pyRevit tools and hit a little snag trying to grab rooms from a linked model. I am using a FilteredElementCollector on the linked document,
roomCollector = DB.FilteredElementCollector(linkDoc).OfCategory(DB.BuiltInCategory.OST_Rooms).ToElements()
print roomCollector
but when I print the result, it’s an empty list:
Just as a check I ran the same code in dynamo, and it worked.
The file I’m testing on is in Revit 2023. I am stumped. Any help would be greatly appreciated!