GDPR Cookie Consent by Free Privacy Policy Generator
post thumb
Asset Control
by Matthias Hanitzsch-Moonlight/ on 16 Apr 2019

Getting and setting status codes with status()

To get or set the status code of a value in Formula Engine code, you use the status() function.

Please see the following example:

price = 100.0;
statusCode = status(price); // == 1, the default

price = status(price, 140);
statusCode = status(price); // == 140, as set in the line above

So, with a single parameter status(x) returns the status code of value x. And with two parameters status(x, s) returns the value, now with status code s. Please, note the value is not changed in place, but a copy of it is returned. Reassign as necessary.

comments powered by Disqus