Exemplo n.º 1
0
        private void Application_Exit(object sender, ExitEventArgs e)
        {
            CSMigrationWrapper mw = (CSMigrationWrapper)Properties["mw"];

            if (mw != null)
            {
                if (mw.UmUser != null) // FBS bug 71047 -- 3/20/12
                {
                    mw.UmUser.Uninit();
                }
                string s = mw.GlobalUninit();

                if (s.Length > 0)
                {
                    bool retval = mw.AvoidInternalErrors(s);
                    if (!retval)
                    {
                        MessageBox.Show(s, "Shutdown error", MessageBoxButton.OK,
                                        MessageBoxImage.Error);
                    }
                }
            }
        }
Exemplo n.º 2
0
        private void Application_Exit(object sender, ExitEventArgs e)
        {
            using (LogBlock logblock = Log.NotTracing()?null: new LogBlock(GetType() + "." + System.Reflection.MethodBase.GetCurrentMethod().Name))
            {
                CSMigrationWrapper mw = (CSMigrationWrapper)Properties["mw"];
                if (mw != null)
                {
                    if (mw.csSourceAccount != null) // FBS bug 71047 -- 3/20/12
                    {
                        mw.csSourceAccount.UninitSourceAccount();
                    }

                    string s = mw.UninitCSMigrationWrapper();
                    if (s.Length > 0)
                    {
                        bool retval = mw.AvoidInternalErrors(s);
                        if (!retval)
                        {
                            MessageBox.Show(s, "Shutdown error", MessageBoxButton.OK, MessageBoxImage.Error);
                        }
                    }
                }
            }
        }