Pulldown Menu button

Got a LiveCode personal license? Are you a beginner, hobbyist or educator that's new to LiveCode? This forum is the place to go for help getting started. Welcome!

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller

Post Reply
Val_UK
Posts: 7
Joined: Fri Jul 22, 2011 3:19 pm

Pulldown Menu button

Post by Val_UK » Fri Jul 22, 2011 8:35 pm

Hi, guys,
How can I call different commands based on what menu is selected in Pulldown Menu button. I know how to do it in RealBasic but I have not figured out how to do it in LiveCode.
Any help is very appreciated.
Val

townsend
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 430
Joined: Sun Feb 13, 2011 8:43 pm

Re: Pulldown Menu button

Post by townsend » Fri Jul 22, 2011 10:30 pm

Welcome to LiveCode. I think this is what you're looking for.

Code: Select all

on menuPick mySelection
     if MySelection = "this" then
          --do this
     else if mySelection = "that" then
          --do something else
     else
          --otherwise do this
     end if
end menuPick

Val_UK
Posts: 7
Joined: Fri Jul 22, 2011 3:19 pm

Re: Pulldown Menu button

Post by Val_UK » Fri Jul 22, 2011 11:47 pm

Townsend,
Thank you for the reply - it really helped.
Val

Post Reply