DataGrid simple question

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

It is probably a very simple question, but I can't find a right DataGrid
property that prevents the user from adding new rows. Of course the
'ReadOnly' property does it, but the grid cannot be read only, since the user
should be allowed to edit existing rows.
However, when I leave ReadOnly set to false, that an empty row is appearing
on the bottom of the grid so that the user can add new rows, which is what I
don't want.
Thanks
Cezar Mart
 
It's a property on the DataView. When you assign to the DataSource of the
DataGrid, use a DataView object and set its AllowNew property to false.
 
Back
Top