learningcsharp
October 12th, 2005, 06:22 PM
i have the rowfilters running functioning individually but now i want to make one button that will pick up all 3 values and rowfilter that way, here is what i have, im pretty sure im goign to need some if/then's to get these 3 criteria to work togather, any help is appreciated!
private void btnSchoolFilter_Click(object sender, System.EventArgs e)
{
objdsStudents.Tables["students"].DefaultView.RowFilter = "schoolID =" + this.comboBox5.SelectedValue.ToString();
this.dataGrid1.Refresh();
}
private void button3_Click(object sender, System.EventArgs e)
{
objdsStudents.Tables["students"].DefaultView.RowFilter = "diabetes = 0";
this.dataGrid1.Refresh();
}
private void button4_Click(object sender, System.EventArgs e)
{
objdsStudents.Tables["students"].DefaultView.RowFilter = "zip =" + this.zipfilter.Text.ToString();
this.dataGrid1.Refresh();
}
private void btnSchoolFilter_Click(object sender, System.EventArgs e)
{
objdsStudents.Tables["students"].DefaultView.RowFilter = "schoolID =" + this.comboBox5.SelectedValue.ToString();
this.dataGrid1.Refresh();
}
private void button3_Click(object sender, System.EventArgs e)
{
objdsStudents.Tables["students"].DefaultView.RowFilter = "diabetes = 0";
this.dataGrid1.Refresh();
}
private void button4_Click(object sender, System.EventArgs e)
{
objdsStudents.Tables["students"].DefaultView.RowFilter = "zip =" + this.zipfilter.Text.ToString();
this.dataGrid1.Refresh();
}