Skip to main content

New Item Row/Card

  • 2 minutes to read

The new item row/card is used to enter new records. In Grid Views, the new item row can be displayed above or below all data and group rows. In Card Views and Layout Views the new item card is displayed as an empty card below all the cards.

 

GridView:

VisualElems_GridView_NewItemRow

CardView:

VisualElems_CardView_NewItemRow

 

Tip

New records are added only when a user starts typing cell values in the New Item Row.

The table below lists the main properties that affect an element’s appearance.

Appearance

The new item row/card uses the data rows and cards display settings.

Row Handle

GridControl.NewItemRowHandle

Availability

For Grid Views, it is possible to use the GridOptionsView.NewItemRowPosition property to make the new item row always enabled.

In Card Views and Layout Views the new item card is only displayed when a new card is added to the View (via the ColumnView.AddNewRow method or embedded navigator).

If the new item row is hidden in a Grid View, it will be displayed when a new row is added to the View via the ColumnView.AddNewRow method or embedded navigator. In this case, the new item row will be hidden when focus is moved to another row.

Position

For Grid Views use the GridOptionsView.NewItemRowPosition property.

Editing

You cannot obtain or modify cell values until there is a row object that corresponds to a record. In case of new rows added via the New Item Row, Data Grid initializes new row objects for these rows only after a user modifies any cell.

Do not manually add or remove rows before a new row object is posted into an underlying Grid data source. Data Grid posts new row objects when the New Item Row loses focus, or when the UpdateCurrentRow method is called.

Custom Value Initialization

ColumnView.InitNewRow

To learn more, see

See Also