Share via


Overview | Methods | Fields | This Package | All Packages

OverviewMethodsFieldsThis PackageAll Packages

DataGrid.setAllowAddNew

Sets a boolean value indicating whether the user can add rows to the grid (provided the underlying recordset allows new records to be added).

Syntax

public void setAllowAddNew( boolean allowAddNew )

Parameters

allowAddNew

Set to true to allow rows to be added to the grid; otherwise, set to false. The default value of the allowAddNew property is true.

Remarks

If the underlying recordset allows new records to be added, setting both the allowAddNew and allowUpdate properties to true causes the DataGrid control to display a blank row after the last row in the grid. The user can then enter a new row of data, which, in turn, adds a new record to the recordset. If either the allowAddNew property or the allowUpdate property is false, no blank row is displayed and a new row cannot be added.

Important   If the recordset does not allow new records to be added, the grid will not display a blank row, even if the allowAddNew and allowUpdate properties are true.

See Also   getAllowAddNew