protected void ASPxGridView1_RowInserting(object sender, DevExpress.Web.Data.ASPxDataInsertingEventArgs e) { if (ASPxGridView1.IsNewRowEditing) { string plineCode = e.NewValues["PLINE_CODE"] as string; string station = e.NewValues["STATION_CODE"] as string; string stationSub = e.NewValues["STATION_CODE_SUB"] as string; StationSubEntity entity = new StationSubEntity { COMPANY_CODE = "01", PLINE_CODE = plineCode, STATION_CODE = station, STATION_CODE_SUB = stationSub }; StationSubFactory.Insert(entity); e.Cancel = true; ASPxGridView1.CancelEdit(); setCondition(); } }