"IF" Logic Error

I have two lists of elements, from which a list is to be chosen based upon a simple logic (x!=0). However it is giving only “FALSE” value even when the logic sent is “TRUE”.

What may possibly have caused this error? Is there a fix to this bug?

you have to make a list of boolean (True, false ) not just one value.
anyway if you want to have the whole list if true, you should make the whole list one item, use List.Create after value if false, and List Create after Value if True ,

then after the result use Flatten

2 Likes

Hey,

IF likes to have lists of the same length, so instead I would use (the principle contained in) the Clockwork ScopeIf+

I would avoid the OOTB ScopeIf as it (uniquely) doesn’t execute the ‘false’ input upstream which can cause your graph to crash if that branch connects to the ‘true’ branch.

Hope that helps,

Mark

4 Likes