private void DeleteSubmitCommand() { try { if (String.IsNullOrEmpty(Convert.ToString(LocCode))) { MessageBox.Show("Customer Code should be Entered", "Process Designer"); } else { MessageBoxResult messageBoxResult = System.Windows.MessageBox.Show("Do you really want to delete this Customer code ?", "Delete Confirmation", System.Windows.MessageBoxButton.YesNo); if (messageBoxResult == MessageBoxResult.Yes) { bool val = oLocMaster.DeleteLocationCode(LocCode, NextAction, ref _errMessage); if (val) { MessageBox.Show(_errMessage, "Process Designer"); ClearOperMaster(); } if (val == false) { if ((string)_errMessage != "") { MessageBox.Show(_errMessage, "Process Designer"); } } } } } catch (Exception ex) { throw ex; } }
private void DeleteSubmitCommand() { try { NextAction = "DELETE"; if (String.IsNullOrEmpty(Convert.ToString(LocCode))) { ShowInformationMessage(PDMsg.NotEmpty("Location Code")); FocusButton = true; //MessageBox.Show("Location Code should be Entered", "SmartPD", MessageBoxButton.OK, MessageBoxImage.Information); } else { MessageBoxResult messageBoxResult = ShowWarningMessage(PDMsg.BeforeDelete("Location code"), MessageBoxButton.YesNo); FocusButton = true; //System.Windows.MessageBox.Show("Do you want to delete this Location code?", ApplicationTitle, System.Windows.MessageBoxButton.YesNo, MessageBoxImage.Question); if (messageBoxResult == MessageBoxResult.Yes) { bool val = oLocMaster.DeleteLocationCode(LocCode, NextAction, ref _errMessage); if (val) { ShowInformationMessage(_errMessage); FocusButton = true; //MessageBox.Show(_errMessage, "SmartPD", MessageBoxButton.OK, MessageBoxImage.Information); ClearOperMaster(); } if (val == false) { if ((string)_errMessage != "") { ShowInformationMessage(_errMessage); } FocusButton = true; //MessageBox.Show(_errMessage, "SmartPD", MessageBoxButton.OK, MessageBoxImage.Information); } } } } catch (Exception ex) { throw ex.LogException(); } }