How to filter by a boolean parameter?

Hello, I am trying to filter by a boolean parameter in a list. I am trying to use it as a bool mask, but its not working. So then I tried to filter by string.contains, but its not working either. So then I tried a list.filter but still no dice. What am I doing wrong. shouldnt the bool mask take bool parameters as a mask? How the heck do I filter this list? Thanks!

Hi @mix ,

first of all, you should use Object.Type on the output of GetParameterValueByName to see what kind of data you’re dealign with (strings, integers etc.) .

Unless you have a list of booleans to filter with, List.Filter is probably the best approach, combined with the filtering condition. Here’s how you can use it:



you can also test your condition , get a boolean list then use it with List.FilterByBooleanMask

6 Likes