I have set up two option menus. Each has a script that puts the label
value into a variable:
ON menuPick theItem
IF theitem is "2006" THEN
put "2006" into eYr
ELSE IF theitem is "2007" THEN
put "2007" into eYr
ELSE IF theitem is "2008" THEN
put "2008" into eYr
ELSE IF thei
Your problem is that you forgot to declare
global eYr
and
global bYr
at the beginning of each handler.
Just curious, theres probably some good reason:
Why didn't you just say:
ON menuPick theItem
global eYr
put theItem into eYr
END menuPick
on menuPick theItem
global bYr
put theItem into bYr
Charles,
Why variables?
on mouseUp
if the label of btn 1 is a number and ¬
the label of btn 2 is a number then
put the label of btn 2 - the label of btn 1 into x
-- do something with x
end if
end mouseUp
No need for a script in the option menu buttons.
Best,
Mark
--
Economy-x-