public void EditDivision(string field, string oldValue, string newValue, object division) { var div = JsonConvert.DeserializeObject <DivisionDTO>(division.ToString()); try { //string message = "<b>Property:</b> {0}<br /><b>Field:</b> {1}<br /><b>Old Value:</b> {2}<br /><b>New Value:</b> {3}"; //// Send Message... //X.Msg.Notify(new NotificationConfig() //{ // Title = "Edit Record #" + div.Id.ToString(), // Html = string.Format(message, div.Id, field, oldValue, newValue), // HideDelay = 1500, // Width = 250, // Height = 150 //}).Show(); //this.DivisionPanel.GetStore().GetById(div.Id).Commit(); var divisionBLL = new DivisionBLL(); var duplicateDivision = divisionBLL.GetDivision(div); if (duplicateDivision == null || duplicateDivision.Id == div.Id) { divisionBLL.UpdateDivisions(div); } else { Ext.Net.Notification.Show(new Ext.Net.NotificationConfig { Title = "Notification", Icon = Ext.Net.Icon.Information, AutoHide = true, HideDelay = 2000, Html = "Division already exists!" }); } LoadMasterData(); } catch (Exception ex) { } }