Code: Select all
If something and if somethingElse then DoSomething
Thanks!
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller
Code: Select all
If something and if somethingElse then DoSomething
Code: Select all
...
if thisandthat AND thatandthis then
...
Code: Select all
switch
case thisandthat
case thatandthis
doSomething
break
case whatever
doSomethingElse
break
end switch
Code: Select all
if (thisandthat AND thatandthis) then
Actually I really meant:dunbarx wrote: ↑Tue Mar 15, 2022 2:44 pmGoing back to the "if" method, you have to understand how LiveCode works.
The statement that Klaus mentioned is really this:You cans that there is only a single "if", as there must be, and that the more "complicated" portion in parentheses is evaluated independently. If that evaluation returns "true", then the "if" will fire.Code: Select all
if (thisandthat AND thatandthis) then
Craig
Code: Select all
if (thisandthat) AND (thatandthis) then
Always, I suppose, but I will bet the issue here is LC syntax, not knowledge of how the world works.Not a bad idea to learn a bit of basic logic and the
satisfaction of truth conditions.