Troubleshooting

New User Menu scripting woes

Started by nbdy on .

Sign in or create an account to join the conversation.

7 posts

Topic starter
Hello All,
I'm a new user and struggling with the Menu item. I have downloaded
and looked at quite a few projects searching for an example.
Have also read thru the pertinent parts of the manual.

My question is...

I have a simple menu with 2 items.
I want to send a different OSC command on selection of
each one of those 2 choices.

Thanks,
nbdy
you need to create a script that executes "on expression" selection.
selection is where the menu object stores your choice. 0 = first choice, 1 = second, etc.

so something like:

if (selection == 0) {
// do these things
} else if (selection == 1) {
// do these other things
}
Thought I had this figured out but perhaps my syntax is incorrect.
The script is still all in red.

my script...
Execution: On Expression, selection

if (selection==0){
oscout (0,'/Server/showcontrol/fadein/')
} else if (selection == 1){
oscout (0,'/server/showcontrol/fadeout/')
}

What am I doing wrong?
Any help would be appreciated

nbdy
ya know Phill999 as I have been reading on the forums and the manual I have seen ARGS[]

what would my ARGS be in this case?

the OSC commands to make this work are as stated in the scout lines of my script.

in my project I have 2 separate CustomButtons that do what I am trying with the menu.
those buttons just send the osc commands

/Server/showcontrol/fadein/
/Server/showcontrol/fadeout/

I'm missing something here.

Thanks,
nbdy