- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-30-2022 01:21 AM - edited 12-30-2022 03:46 AM
I have a flow designer on Property table that need to validate the value of a T/F type property . The results seems inconsistent.
I created a flow designer variables of type True/False .
For 1st validation , I assigned flow variable "propertyValue" the value of system property using return Boolean(fd_data.trigger.current.value);
After X amount of time waiting , it needs to validate again .
For 2nd validation. I used the below script to set the value for flow variable "propertyValueAfter" .
The issue here is although flow variables have the correct value , the If condition in flow always seem to validate them as true .
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-30-2022 04:11 AM
I modified my flow to use script to set the value as "active " based on True or false. and then use that new value in if condition.
If value = active , instead of value = true or false.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-30-2022 02:02 AM
Hi,
You cannot validate a string to boolean in this manner.
The conversion will always return true if the variable has some value.
So you will need to do the comparison in some other way.
Example below
var someText = 'hello';
var boo = Boolean(someText);
// boo will be set to true, since someText has a value
var someText2 = '';
var boo2 = Boolean(someText2);
// boo2 will be set to false, since someText2 has no value
// instead do a comparison something like this
var someVariable = gs.getProperty('someProperty');
if (someVariable && someVariable == 'true')
You can learn more on the Boolean method here:
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-30-2022 04:11 AM
I modified my flow to use script to set the value as "active " based on True or false. and then use that new value in if condition.
If value = active , instead of value = true or false.