No edit summary |
WoWWiki-Bam@legacy41582782 (talk | contribs) No edit summary |
||
Line 34: | Line 34: | ||
====Result==== |
====Result==== |
||
Button is unchecked |
Button is unchecked |
||
+ | |||
+ | |||
+ | ---- |
||
+ | ====Patch 1.11 WARNING==== |
||
+ | In patch 1.11 it seems like this method was changed so that it no longer works when passing '''nil''' as argument. I have tested that it works as intended when passing '''true''' and '''false'''. |
Revision as of 05:19, 22 June 2006
The API is no longer being updated here until further notice. |
Sets the status of a CheckButton.
CheckButton:SetChecked(State);
Parameters
Arguments
- (State)
- State
- Mixed - Basically expressions LUA evaluates to a number will check the button. Everything else will uncheck.
Returns
- nil
- nil
- This function will always return nil.
Example
CheckButton:SetChecked(true); CheckButton:SetChecked(1); CheckButton:SetChecked(-2397); CheckButton:SetChecked("-2397");
Result
Button is checked
Example
CheckButton:SetChecked(false); CheckButton:SetChecked(0); CheckButton:SetChecked("foo"); CheckButton:SetChecked(); CheckButton:SetChecked({1,2,3});
Result
Button is unchecked
Patch 1.11 WARNING
In patch 1.11 it seems like this method was changed so that it no longer works when passing nil as argument. I have tested that it works as intended when passing true and false.