I am trying to filter walls. For that I use
categories = List[ElementId]()
myId = ElementId(BuiltInCategory.OST_Walls)
categories.Add(myId)
..but this obviously doesn't return a valid ElementId, as when I print it, it has some negative value (and if I print "doc.GetElement(myId)", I get "None").
Then, indeed when creating the filter...
filter = ParameterFilterElement.Create(doc, "Walls filter", categories)
...I get an ArgumentException. I'm using Revit 2019 (with pyRevit). As far as I remember, it used to work with Revit 2018, but I don't see any reason it shouldn't anymore. What am I missing?
Thanks a lot!