Example #1
0
        private string InitDelete(long?ID)
        {
            try
            {
                if (ID.HasValue)
                {
                    ReasonServices.Delete(ID.GetValueOrDefault());
                }
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.Message, "Notification", MessageBoxButton.OK);
            }

            return("OK!");
        }
Example #2
0
        private bool InitDelete(long ID)
        {
            bool ok = false;

            try
            {
                if (ID != 0)
                {
                    ok = ReasonServices.Delete(ID);
                }
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.Message, "Notification", MessageBoxButton.OK);
            }

            return(ok);
        }