I suggest you create a
Dictionary<CheckBox, TextBox>
private Dictionary<CheckBox, TextBox> CbxTpTBx;
CbxTpTBx = new Dictionary<CheckBox, TextBox>
{
{checkBox1, textBox1}, {checkBox2, textBox2}, {checkBox3, textBox3}
};
... then:
1) at design time:
a) select all the CheckBoxes on your form or container control
b) open the Properties browser (F4) and select/double-click the _CheckStateChanged Event to write the event handler in your form
c) edit the event handler so it looks something like this
private CheckBox currentBox;
private void checkBox3_CheckStateChanged(object sender, EventArgs e)
{
currentBox = sender as CheckBox;
CbxTpTBx[currentBox].Enabled = currentBox.Checked;
}