private void comboBoxSorceName_SelectedIndexChanged(object sender, EventArgs e) { try { sourceControl = new SourceControl(); string sourceName = comboBoxSorceName.Text; string address = sourceControl.getSourceAddress(sourceName); string employee1 = sourceControl.getSourceEmployee1(sourceName); string employee2 = sourceControl.getSourceEmployee2(sourceName); string phone1 = sourceControl.getSourcePhone1(sourceName); string phone2 = sourceControl.getSourcePhone2(sourceName); string phone3 = sourceControl.getSourcePhone3(sourceName); txtSourceName.Text = sourceName; txtSourceAddress.Text = address; txtSourceEmployee1.Text = employee1; txtSourceEmployee2.Text = employee2; txtSourcePhone1.Text = phone1; txtSourcePhone2.Text = phone2; txtSourcePhone3.Text = phone3; } catch (Exception ex) { MessageBox.Show(ex.Message); } }