Embedded Complex Expression Wait>{If(%i%>1),1,2}

Technical support and scripting issues

Moderators: JRL, Dorian (MJT support)

Post Reply
armsys
Automation Wizard
Posts: 1108
Joined: Wed Dec 04, 2002 10:28 am
Location: Hong Kong

Embedded Complex Expression Wait>{If(%i%>1),1,2}

Post by armsys » Tue Apr 22, 2008 11:08 pm

Can or will MS support embedded Complex Expression such as Wait>{If(%i%>1),1,2}?

User avatar
Marcus Tettmar
Site Admin
Posts: 7395
Joined: Thu Sep 19, 2002 3:00 pm
Location: Dorset, UK
Contact:

Post by Marcus Tettmar » Tue Apr 22, 2008 11:37 pm

You can use complex expressions in other commands. E.g. this works:

Let>x=5
Wait>{%x%*2}

But {If(%i%>1),1,2} is not a valid complex expression. Looks like you want "inline ifs" which don't currently exist in complex expressions.
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar

Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?

armsys
Automation Wizard
Posts: 1108
Joined: Wed Dec 04, 2002 10:28 am
Location: Hong Kong

Post by armsys » Wed Apr 23, 2008 4:44 am

Thanks for your guidance.
How about:
Wait>{if(%i%>1,10,5)}
Is the latter a valid MS statement?
As a matter of fact, I'm already amazed by MS's allowing the omplex expresions in the Wait> command. It helps substantially simplify the code.

Post Reply
cron
Sign up to our newsletter for free automation tips, tricks & discounts