Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Avoiding DataGrid Adding New Rows
Message
 
To
19/05/2003 04:36:26
General information
Forum:
ASP.NET
Category:
Other
Miscellaneous
Thread ID:
00789791
Message ID:
00790167
Views:
21
It works perfectly, but how to involve the data relation in it?

Current code:
myDS.Relations.Add("EmpUsrRts", myDS.Tables("Employee").Columns("EmployeeID"), myDS.Tables("UserRights").Columns("EmployeeID"))

Me.dgUserRights.SetDataBinding(myDS, "Employee.EmpUsrRts")
Thanks again Plamen


>No, you do not need to change or remove your DataSet. Just bind DataGrid to the DataView of the table. If now you have:
>
>DataGrid1.DataSource = DataSet1.Tables(0)
>
>you must change this to:
>
>DataSet1.Tables(0).DefaultView.AllowNew = False
>DataGrid1.DataSource = DataSet1.Tables(0).DefaultView
>
<><><><><><><><><><><><><><><><><><><><>
<><> REMEMBER,,,,KNOWLEDGE IS POWER <><>
<><><><><><><><><><><><><><><><><><><><>
Previous
Reply
Map
View

Click here to load this message in the networking platform