Good evening,
Can someone please advise me how I get around the exception I'm getting here?I have four combo boxes with items in. When I select one I get the following error. I am using VS2013
private void incLog_Load(object sender, EventArgs e)
{
}
public Object SelectedItem { get; set; }
private void comboBox1_SelectedIndexChanged(object sender, EventArgs e)
int selectedIndex = comboBox1.SelectedIndex;
Object selectedItem = comboBox1.SelectedItem;
Clipboard.SetText(selectedItem.ToString() + "\r\n");
comboBox1.SelectedIndex = -1;
private void comboBox2_SelectedIndexChanged(object sender, EventArgs e)
int selectedIndex = comboBox2.SelectedIndex;
Object selectedItem = comboBox2.SelectedItem;
comboBox2.SelectedIndex = -1;
private void comboBox3_SelectedIndexChanged(object sender, EventArgs e)
int selectedIndex = comboBox3.SelectedIndex;
Object selectedItem = comboBox3.SelectedItem;
comboBox3.SelectedIndex = -1;
private void comboBox4_SelectedIndexChanged(object sender, EventArgs e)
int selectedIndex = comboBox4.SelectedIndex;
Object selectedItem = comboBox4.SelectedItem;
Clipboard.SetText(selectedItem.ToString() + "\n");
comboBox4.SelectedIndex = -1;