ComponentOne FlexGrid for WinForms
AllowAddNew Property

C1.Win.C1FlexGrid Namespace > C1FlexGridBase Class : AllowAddNew Property
Gets or sets whether the grid should display a new row template after the last data row.
Syntax
'Declaration
 
Public Property AllowAddNew As Boolean
public bool AllowAddNew {get; set;}
Remarks

If the user enters data into the new row template, a new row is automatically added to the grid.

This property works in bound mode (if the data source supports adding new rows) and also in unbound mode.

Note that if this property is set to true, the Rows.Count property will return a value that includes the new row template. If you set the Rows.Count property, the grid will set the number of data rows and will automatically add the new row template. For example:

flex.AllowAddNew = true; flex.Rows.Count = 10; Console.WriteLine("Row count is {0}.", _flex.Rows.Count); Row count is 11.
See Also

Reference

C1FlexGridBase Class
C1FlexGridBase Members