I’m just trying to use OfCategory in a FilteredElementCollector and I feel like this has always had one argument.
views = ((FilteredElementCollector.OfCategory(BuiltInCategory.OST_Views)
.WhereElementIsNotElementType()
.WherePasses(ElementParameterFilter(FilterStringRule(ParameterValueProvider(ElementId(BuiltInParameter.SYMBOL_NAME_PARAM)),FilterStringEquals(),"Legend Creation", True))))
.ToElements())
IronPython Traceback:
Traceback (most recent call last):
File "L:\Revit\Development\PyRevit\DevTool\DevTool.extension\DevTools.tab\Family Tools.Panel\GenerateImageofFamily.pushbutton\GenerateImageofFamily_script.py", line 38, in <module>
TypeError: OfCategory() takes exactly 2 arguments (1 given)
OfClass is giving me the same error.