Programmatically Click a Checkbox

MinusZero

18-06-2018

I know how to change the rawValue of a checkbox in event code, but it is possible to simulate a click like with a button.

With a button i can do :

Button1.execEvent("click");

to click it and by doing so, the click event code will execute.

When i change the rawValue of a checkbox, the check goes on or off but the change event does not execute. It would be great to not have to duplicate code to have the same effect.

Accepted Solutions (1)

Accepted Solutions (1)

MinusZero

18-06-2018

Never mind, solved in record time...sometimes reading the help works

CheckBox1.execEvent("change");

this did the trick, it didn't check the box too, but the code in the change event executed which is what i wanted.

Answers (0)