CheckBox.Checked
event · CheckBox · cAlgo.API
DesktopCLICloud
Occurs when checked.
Environment behaviour
CLI — not supported. Accepted without error but never displayed, so control events such as Click are never raised.
Cloud — not supported. Accepted without error but never displayed, so control events such as Click are never raised.
Definition
public event Action<CheckBoxEventArgs> Checked;
checkBox.Checked += handler # handler(obj: CheckBoxEventArgs)
Examples
var checkBox = new CheckBox { Text = "Trailing stop" };
checkBox.Checked += args => Print("Trailing stop enabled");
Chart.AddControl(checkBox);
def on_start(self):
checkBox = CheckBox()
checkBox.Text = "Trailing stop"
checkBox.Checked += self.on_check_box_checked
api.Chart.AddControl(checkBox)
def on_check_box_checked(self, args):
api.Print("Trailing stop enabled")