I have 100 checkbox in a winfrom.
Their name is sequential like checkbox1,checkbox2 etc.
I have a submit button in my winform. After clicking the submitting button, it check
foreach (var control in this.Controls) // I guess this is your form
{
if (control is CheckBox)
{
if (((CheckBox)control).Checked)
{
//update
}
else
{
//update another
}
}
}