开发者

In Flex, how do I create a CheckBox that can't be un-checked?

开发者 https://www.devze.com 2022-12-25 03:29 出处:网络
In Flex, how do I create a CheckBox that can\'t be un-checked? I run a function when the checkbox is clicked. If that function encounters an error, I want the state of the checkbox to remain the same.

In Flex, how do I create a CheckBox that can't be un-checked? I run a function when the checkbox is clicked. If that function encounters an error, I want the state of the checkbox to remain the same. How do I do tha开发者_如何学Pythont?


You can use the enabled attribute to prevent the checkbox from being accessed once it's in the state you mentioned.

onFunctionError():void {
    yourCheckbox.enabled = false;
}
0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号