private void cbFilterEU_SelectedIndexChanged(object sender, EventArgs e) { string check = cbFilterEU.SelectedItem.ToString(); if (check == "All") { MessageBox.Show("All Data !!!"); } else if (cbFillFilterEIU.SelectedItem != null) { //Check an see what's in the dgv DataView dv = new DataView(dt); // now filter dv.RowFilter = " [Areacode] = " + cbFilterEU.Text.Trim(); MessageBox.Show("AREACODE"); datagridview1.DataSource = dv; } else if { /* Wanna look through the datagridview for the column name and if not present show message MessageBox.Show("Can't find the column"); */ }
//else if (cbFilterEU.SelectedItem != null && datagridview1 == null) //{ // MessageBox.Show("Can't find the column"); //}
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)