Beispiel #1
0
 private static void InitializeApp(App app)
 {
     _appBoot = new AppBoot(app);
     _appBoot.Initialize();
     _appBoot.Navigate <MasterViewModel>();
     _appBoot.Show();
 }
Beispiel #2
0
        private static void InitializeApp(App app)
        {
            Application.Current.DispatcherUnhandledException += (sender, e) =>
            {
                Logger.Log(new LogEntry(LoggingEventType.Fatal, "Unhandled Exception", e.Exception));
                MessageBox.Show(e.Exception.Message, "An exception has occurred. ", MessageBoxButton.OK, MessageBoxImage.Error);
            };

            LogViewModel.Write("Resources loaded");
            LogViewModel.Write("Application starting");
            Logger.Log(new LogEntry(LoggingEventType.Information, "EasyFarm Started ..."));

            _appBoot = new AppBoot(app);
            _appBoot.Initialize();
            _appBoot.Navigate <MasterViewModel>();
            _appBoot.Show();
        }