Freeze a Checkbox
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller
Freeze a Checkbox
Is there a way to have a checkbox "Stay" selected once it is checked?Even if the user clicks on it again?
Thanks
Bidge
Thanks
Bidge
-
- Livecode Opensource Backer
- Posts: 404
- Joined: Tue Jan 08, 2008 3:44 pm
- Location: Kent, UK
- Contact:
Hi Bidge, one way would be:
Code: Select all
on mouseUp
if the hilite of me is true then
exit mouseUp
else
if the hilite of me is false then
set the hilite of me to true
end if
end if
end mouseUp
-
- VIP Livecode Opensource Backer
- Posts: 3581
- Joined: Mon Jan 22, 2007 7:36 am
- Location: Berkeley, CA, US
- Contact:
Bidge-
Not really sure why you'd want to do this, but I can condense gyro's answer even further:
<g>
Not really sure why you'd want to do this, but I can condense gyro's answer even further:
Code: Select all
on mouseUp
set the hilite of me to true
end mouseUp
-
- VIP Livecode Opensource Backer
- Posts: 4003
- Joined: Sun Jan 07, 2007 9:12 pm
- Location: Bochum, Germany
Bidge,
you confuse the user if you offer him a checkbox and the user can not check it. For the user interface it would be better to disable a checkbox if you want to freeze it.this dimms the checkbox and the user has a clue that it is not functional. Otherwise the user thinks your program does not work.
regards
Bernd
you confuse the user if you offer him a checkbox and the user can not check it. For the user interface it would be better to disable a checkbox if you want to freeze it.
Code: Select all
set the disabled of btn 1 to true
regards
Bernd
-
- Livecode Opensource Backer
- Posts: 404
- Joined: Tue Jan 08, 2008 3:44 pm
- Location: Kent, UK
- Contact:
Doh, again!! I'd swear in court that that didn't work for me last night! Although in the light of day I see that it must. (I replied at a quarter to 2 in the morning: that is my excuse for the day...Not really sure why you'd want to do this, but I can condense gyro's answer even further:
Code: Select all
on mouseUp set the hilite of me to true end mouseUp