B
Brett Romero
I have a dataset with one table, which has four columns. All are of
type INT. I need to convert this dataset into a dataview so I can sort
on the last three columns. I may sort one of the three or all three at
once. This dataview will display its results in a winform datagrid.
Right now, I create the dataset from a datareader:
while(dr.Read())
{
drow = _filteredCriteriaDataSet.Tables[0].NewRow();
drow[0] = dr.GetValue(0);
drow[1] = dr.GetValue(1);
drow[2] = dr.GetValue(2);
drow[3] = dr.GetValue(3);
_filteredCriteriaDataSet.Tables[0].Rows.Add(drow);
}
How do I convert the dataset to a dataview then take the three criteria
and apply them to the new created dataview?
Thanks,
Brett
type INT. I need to convert this dataset into a dataview so I can sort
on the last three columns. I may sort one of the three or all three at
once. This dataview will display its results in a winform datagrid.
Right now, I create the dataset from a datareader:
while(dr.Read())
{
drow = _filteredCriteriaDataSet.Tables[0].NewRow();
drow[0] = dr.GetValue(0);
drow[1] = dr.GetValue(1);
drow[2] = dr.GetValue(2);
drow[3] = dr.GetValue(3);
_filteredCriteriaDataSet.Tables[0].Rows.Add(drow);
}
How do I convert the dataset to a dataview then take the three criteria
and apply them to the new created dataview?
Thanks,
Brett