protected void gvMappedSchemes_UpdateCommand(object sender, GridCommandEventArgs e) { GridEditableItem item = (GridEditableItem)e.Item; int setupId = int.Parse(item.GetDataKeyValue("ACSTSM_SetupId").ToString()); DateTime oldDate = DateTime.Parse(item.SavedOldValues["ValidTill"].ToString()); DateTime newDate = ((RadDatePicker)item["schemeValidTill"].Controls[0]).SelectedDate.Value; //check whether it is not associated int retVal = commisionReceivableBo.updateStructureToSchemeMapping(setupId, newDate); if (retVal < 1) { return; } CreateMappedSchemeGrid(); }