Q:

How to get index value in combo box? 

I have a ComboBox with two values 'cash' and 'bank' if the user selects bank I need to enable two controls.  I've tried below code:
private void comboBox_pay_type_SelectedIndexChanged(object sender, EventArgs e)
    {
        if (comboBox_bank. SelectedIndex == 1)
        {
            comboBox_bank. Enabled = true;
            textBox_recp_no. Enabled = true;
        }
    }

Problem is the index value is -1 for both cash and bank.  Where have I made an error? 

A:

You're just referencing the wrong combo box:
private void comboBox_pay_type_SelectedIndexChanged(object sender, EventArgs e)
{
    if (comboBox_pay. SelectedIndex == 1)
    {
        comboBox_bank. Enabled = true;
        textBox_recp_no. Enabled = true;
    }
}

You need to reference comboBox_pay here.