How to: Add and Initialize a New Row

In this example the ASPxGridView.InitNewRow event is handled to initialize the new record's field values with default values.

The image below shows the result:

exInitNewRow

protected void grid_InitNewRow(object sender, DevExpress.Web.Data.ASPxDataInitNewRowEventArgs e) {
    e.NewValues["BirthDate"] = new DateTime(1970, 1, 10);
    e.NewValues["Title"] = "Sales Representative";
}