Discussion:
conditional calculation
Jean-Luc Arnaud
2017-01-31 16:15:08 UTC
Permalink
Hi all,

Is there a way to calculate this way (like Excel does):

MyVar=2+(If(MyVar2>3;1;3))

I believe I read something about that in a Release Notes, but don't
remember where (I'm not even sure).

TIA
--
Jean-Luc Arnaud


_______________________________________________

Xojo forum:

https://forum.xojo.com/
vaughnsc .
2017-01-31 16:23:55 UTC
Permalink
A quick look suggests the new (ternary) IF syntax was added in 2014 e.g.
"result=if(condition,x,y)"

On Jan 31, 2017 12:15 PM, "Jean-Luc Arnaud" <jean-***@cdmultimedia.fr>
wrote:

Hi all,

Is there a way to calculate this way (like Excel does):

MyVar=2+(If(MyVar2>3;1;3))

I believe I read something about that in a Release Notes, but don't
remember where (I'm not even sure).

TIA
--
Jean-Luc Arnaud


_______________________________________________

Xojo forum:

https://forum.xojo.com/
_______________________________________________

Xojo forum:

https://forum.xojo.com/
Jean-Luc Arnaud
2017-01-31 17:19:26 UTC
Permalink
Thanks a lot, Vaughn.


Jean-Luc Arnaud
Post by vaughnsc .
A quick look suggests the new (ternary) IF syntax was added in 2014 e.g.
"result=if(condition,x,y)"
Hi all,
MyVar=2+(If(MyVar2>3;1;3))
I believe I read something about that in a Release Notes, but don't
remember where (I'm not even sure).
TIA
_______________________________________________

Xojo forum:

https://forum.xojo.com/

Loading...