Okay this one's pretty straightforward. I'm creating a checkbox in my Page.xaml.cs file, and assigning it some params. I need to link to events for checked and unchecked. What is the syntax for this?
Also, my current code looks like this:
CheckBox cb = new CheckBox();
cb.IsChecked = true;
System.Windows.Thickness t1 = new Thickness(425,10,0,0);
cb.Margin = t1;
cb.Content = "Checkbox1";
I tried adding my function to cb.Checked but it gives me the following error: "The event 'System.Windows.Controls.Primitives.ToggleButton.Checked' can only appear on the left hand side of += or -="
CheckHandler is defined separately
public void CheckHandler(Object obj, EventArgs e)
{
// Random stuff here
}