The real issue is when you are using the expression, it is returning the result of the expression as the value of the variable. So, when the variable is actually false, it sets the value of the variable as true (the return value of the expression)
I think the flow looks right.
The Create action should initialise the boolean to true. Then any of the changes in your decision splits should set it to false if there was a problem. Finally at the end you check the boolean, and if it’s false you stop, and true you carry on.
Is this how you have it setup?
How are you checking the values in your decision splits? Can you give some examples?
Yes, just like you said.
The variable is set to true at the beginning and changed to false if the forms are not filled in. At the end, if the variable is true, the object will be commited, if not, the flow will end with no actions.
I’m checking the values with this rule called “String_NotEmpty”:
$InputToCheck != empty
Here is the last step of the microflow.
This is where I check if the user has filled the “Name” field. I posted the “String_NotEmpty” rule in a previous comment.
This is the block where I change the variable.
I noticed that the first one sets it as false like it should, but after the second one, it turns back to true, then after the third one it turns back to true. This microflow only works if there is an odd number of fields to check, If it’s even it doesn’t work.
I actually copied this microflow from the “Crash Course” course from the Mendix Academy and that has the same problem as well.
Thanks guys, you solved it! I just have to write “false” in the value window.
I’m so dumb.
Thnak you so much!