private void MakeDataView()
{
DataView dv = new DataView();
dv.Table = DataSet1.Tables["Suppliers"];
dv.AllowDelete = true;
dv.AllowEdit = true;
dv.AllowNew = true;
dv.RowFilter = "City = 'Berlin'";
dv.RowStateFilter = DataViewRowState.ModifiedCurrent;
dv.Sort = "CompanyName DESC";
// Simple bind to a TextBox control
Text1.DataBindings.Add("Text", dv, "CompanyName");
}
No comments:
Post a Comment