Liane Judith
Liane Judith

Reputation: 1

How can i make my checkbox checked by itself

I'm basically facing an issue with a checkbox. Indeed, I'd like to use a button which is gonna look for a boolean value in my database, and if the value is true and that i click on the button, the box is going to get checked by itself.

if(myValue.isTrue()) 
{
this.mybox."getchecked()";
}

But I don't know how to do so, which methods to use, and have not been able to find any results for netbeans do you guys have any solution, thanks for all.

Upvotes: 0

Views: 92

Answers (1)

jwanger
jwanger

Reputation: 84

This can be done by: this.mybox.setSelected(true);

Upvotes: 1

Related Questions