private void comboBox2_DropDown(object sender, EventArgs e) { cn.Open(); //comboBox2.DataSource = parentBindingSource; SqlCommand cb2 = new SqlCommand("SELECT * FROM PARENT WHERE RootID = " + comboBox1.SelectedValue.ToString(), cn); SqlDataAdapter dat = new SqlDataAdapter(cb2); DataSet ds = new DataSet(); dat.Fill(ds, "Parent"); comboBox2.DataSource = ds; cn.Close(); }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)