Reset button didn´t hide my checkbox as default
Copy link to clipboard
Copied
Hi everyone.
I´ve got this problem that one of my check boxes didn't hide again after clicking on my reset button as it should do.
The code behind of it is this one:
this.getField("box").display = (this.getField("s").isBoxChecked(0)) || (this.getField("s+r").isBoxChecked(0)) ||
(this.getField("g").isBoxChecked(0)) || (this.getField("g+s").isBoxChecked(0)) ||
(this.getField("g+s+r").isBoxChecked(0)) || (this.getField("o").isBoxChecked(0)) ||
(this.getField("o+").isBoxChecked(0)) ? display.visible : display.hidden;
So it should just hide or show on the choice of the user. Can someone see what I'm doing wrong?
I'm sorry for my bad English.
Copy link to clipboard
Copied
Try this:
this.getField("box").display = (this.getField("s").isBoxChecked(0) || this.getField("s+r").isBoxChecked(0) ||
this.getField("g").isBoxChecked(0) || this.getField("g+s").isBoxChecked(0) ||
this.getField("g+s+r").isBoxChecked(0) || this.getField("o").isBoxChecked(0) ||
this.getField("o+").isBoxChecked(0)) ? display.visible : display.hidden;

