# Monday, November 22, 2004
Monday, November 22, 2004 5:05:24 PM (GMT Standard Time, UTC+00:00) ( .Net Windows Forms )

i found a few work arounds to prevent a datagrid from displaying the * new row. one of them involved using a dataview as the datasource, with AllowNew property set to false. however, someone called Sameers from theAngrycodeR pointed out that a datatable has a DefaultView property which also has this AllowNew property. so you can use the following code (if your datasource is a dataset):

this.dataSet1.Tables[0].DefaultView.AllowNew = false;

and you get to keep the dataset or datatable as the direct datasource.

Comments [0] | | # 
Name
E-mail
Home page

Comment (HTML not allowed)  

Enter the code shown (prevents robots):

Live Comment Preview