Exemple #1
0
        protected override void OnActivated(EventArgs e)
        {
            bool b = RestConnection.GetRestConnection().TestConnectionAsync();

            if (!b)
            {
                if (MessageBox.Show("Application Server not found", "Internal Server Error", MessageBoxButton.OK, MessageBoxImage.Error) == MessageBoxResult.OK)
                {
                    Current.Shutdown();
                }
            }

            base.OnActivated(e);
            IMenuRegistryProvider registryProvider = ServiceLocator.Current.GetInstance <IMenuRegistryProvider>();

            registryProvider.InitializeMenu();
            IApplicationController controller = ServiceLocator.Current.GetInstance <IApplicationController>();

            controller.InitializeApplication();
        }