cancel
Showing results for 
Search instead for 
Did you mean: 
ConradSteigeman
Level 3
Status: New
Sometimes it is useful to use the numbers 1 and 0 instead of True and False. For example, one just needs to add up all variables to know how many are set True.

Sadly, a direct convertion of the data formats is not supported by Blue Prism. The calculation 'ToNumber(True)' creates an error. Doing it by hand would be possible, but time consuming and could probably be implemented in a faster way.

In this context,  the implementation of the signum function sgn(.) would be handy too.
1 Comment
NicholasZejdlik
Level 9
This seems like it would be a poor man's version of the IIf() function in Visual Basic. If ToNumber converted True to 1 and False to 0, it would lead to expressions like this:
ToNumber([A] > 500) * [A]​

Which is basically a less flexible way of doing this:
IIf([A] > 500, [A], 0)​


While there are many instances where it would be nice to have such a function in an expression, it could also be abused and lead to some ugly results.