Page 1 of 1

How to script a menu selection?

Posted: Thu Jul 22, 2010 1:21 pm
by Clarkey
Hi folks, Please can anyone explain the syntax needed to set a menu option via scripting - or point me in the right direction?

I'm using an option menu to apply preset filters to a list field and when the card opens, I'd prefer to have the menu show the 'All items' choice rather than its name/label.

It's probably a one-liner but I'm currently searching in vain - what's the secret keyword?
Best,
Keith..

Re: How to script a menu selection?

Posted: Thu Jul 22, 2010 1:31 pm
by Janschenkel
You can either set the label property or the menuHistory property of the menu button, depending on whether or not something special happens when the user picks the 'All items' choice manually. Setting the label simply changes what is displayed; setting the menuHistory also triggers a menuPick event in the menu button.

HTH,

Jan Schenkel.

Re: How to script a menu selection?

Posted: Thu Jul 22, 2010 2:04 pm
by Clarkey
Thanks for the insight Jan - menuHistory did the trick! :D
Best,
Keith..