Skip to main content

CheckButton.Toggle() Method

Toggles the button’s check state.

Namespace: DevExpress.XtraEditors

Assembly: DevExpress.XtraEditors.v25.2.dll

NuGet Package: DevExpress.Win.Navigation

Declaration

public virtual void Toggle()

Remarks

Toggle sets the Checked property to true if it was false, and to false if it was true. The CheckedChanged event fires after the state changes.

Use the Checked property to specify the checked state.

The following code snippet toggles a button’s state:

checkButton1.Toggle();

// Equivalent to:
checkButton1.Checked = !checkButton1.Checked;
See Also