Is it possible to use the icon as conditional statement for if then else?
Example that I tried:
Code: Select all
if the icon of button "ButtonTest" is "TurnOn" then
set the icon of button "ButtonTest" to "TurnOff"
end if
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller
Code: Select all
if the icon of button "ButtonTest" is "TurnOn" then
set the icon of button "ButtonTest" to "TurnOff"
end if
Code: Select all
on mouseUp
if the icon of button "buttonTest" is the short id of image "turnOn" then
set the icon of button "buttonTest" to the short id of image "turnOff"
else
set the icon of button "buttonTest" to the short id of image "turnOn"
end if
end mouseUp
Code: Select all
on mouseUp
if the icon of button "ButtonTest" is the short id of image "TurnOn.png" then
set the icon of me to "TurnOff.png"
end if
end mouseUp