Multiple Filters each with a single Rule


#1

I’m creating a graph that will find all the Ceiling Heights in a project and create a Filter for each height found.
I;ve got most everything working, but when it gets down to the node the creates the filter, it pumps all of the Heights into every Filter.
Obviously Equals 8’-0" AND Equals 8’-6" AND Equals 9’-0" AND Equals 9’-6" isn’t going to work very well.
I plan on using this node for other purposes later, so I made it as a Custom Node.
The Node creates (in this case) 4 Filters as expected, but it adds all of the conditions.
I need to just have the first filter use the first condition, the second use second, etc.
I’m passing Lists, but they are only one Level deep, so “Use Levels” won’t help.
Here’s what I’m pumpin in to the node


Here’s the node image

And the node itself. Tons of “Watches” in a fruitless effort to help me debug
CreateSingleFilter.dyf (13.7 KB)
I need it to return each Filter with one condition


#2

You have to pay attention to your list structure. When you separate the parameter values in to separate lists and keep the list structure, you are creating separate rules. If not you will have This AND that AND… Hope it works for you. Its all in the list structure.


#3

Thanks Azubike!
That did it. I never really understood how that “Keep Structure” option worked before.
BTW, I see you used the archi-lab ViewFilter nodes in your example.
That’s how I got here in the first place. I had a working version of my graph, but in Revit 1.3 those (or similar) nodes are now in Core Revit Dynamo and have been deprecated from archi-lab 2016.13, so if that’s a real graph you showed, you’ll have to redo it soon.
And, if you do use the new ViewFilter.SetFilterOverrides, see my other post


#4

Just as a followup to my own post:
This graph was working fine up through Dynamo 1.3.2
When I upgraded to 1.3.3, now my graph fails & I have not been able to find out why.
Not other changes made other than the upgrade to 1.3.3
It seems that the ParameterFilterElement.ByRules node doesn’t like to be passed multiple Filter names anymore