protected override void OnStartup(StartupEventArgs e) { base.OnStartup(e); ApplicationThemeHelper.UpdateApplicationThemeName(); DbEngineDetector.PatchConnectionStringsAndConfigureEntityFrameworkDefaultConnectionFactory(); Database.SetInitializer <DepartmentContext>(new DepartmentContextInitializer()); }
protected override void OnStartup(StartupEventArgs e) { //Configure theme manager DXSplashScreen.Show <SETSplashScreen>(); ApplicationThemeHelper.UpdateApplicationThemeName(); ThemeManager.ApplicationThemeChanged += this.ThemeManager_ApplicationThemeChanged; GridControl.AllowInfiniteGridSize = true; //DomainManager domainManager = new DomainManager(); //UserServiceProvider userServiceProvider = new UserServiceProvider(new InventoryContext(), domainManager); //LogInService logInService = new LogInService(domainManager, userServiceProvider); //var responce = logInService.LogInWithPassword("AElmendo", "Drizzle123!", false, InventorySoftwareType.PRODUCTS_SALES); //this.userService = responce.Service; Current.ShutdownMode = ShutdownMode.OnExplicitShutdown; if (this.ShowLogin()) { Current.ShutdownMode = ShutdownMode.OnMainWindowClose; } else { Current.ShutdownMode = ShutdownMode.OnMainWindowClose; this.Shutdown(); } base.OnStartup(e); }
protected override void OnStartup(StartupEventArgs e) { base.OnStartup(e); ApplicationThemeHelper.UpdateApplicationThemeName(); DbEngineDetector.PatchConnectionStringsAndConfigureEntityFrameworkDefaultConnectionFactory(); Database.SetInitializer <SchoolContext>(new SchoolContextInitializer()); MetadataLocator.Default = MetadataLocator.Create().AddMetadata <SchoolContextMetadata>(); }
protected override void OnStartup(StartupEventArgs e) { base.OnStartup(e); ApplicationThemeHelper.UpdateApplicationThemeName(); InitializeInstances(); }
protected override void OnStartup(StartupEventArgs e) { base.OnStartup(e); ApplicationThemeHelper.UpdateApplicationThemeName(); using (var context = new DepartmentContext()) { context.Database.Migrate(); context.EnsureSeedData(); } }
protected override void OnStartup(StartupEventArgs e) { PresentationTraceSources.Refresh(); PresentationTraceSources.DataBindingSource.Listeners.Add(new ConsoleTraceListener()); PresentationTraceSources.DataBindingSource.Listeners.Add(new DebugTraceListener()); PresentationTraceSources.DataBindingSource.Switch.Level = SourceLevels.Warning | SourceLevels.Error; base.OnStartup(e); DXSplashScreen.Show <SplashScreenView>(); ApplicationThemeHelper.UpdateApplicationThemeName(); }
protected override void OnStartup(StartupEventArgs e) { base.OnStartup(e); RxApp.MainThreadScheduler = new DispatcherScheduler(Dispatcher); DXSplashScreen.Show <StartScreen>(); ApplicationThemeHelper.UpdateApplicationThemeName(); bootstrapper = new Bootstrapper(); bootstrapper.Run(); Current.MainWindow.Show(); DXSplashScreen.Close(); }
private void ApplicationStartup(object sender, StartupEventArgs e) { ApplicationThemeHelper.UpdateApplicationThemeName(); DXSplashScreen.Show <SplashWindow>(); var mainWindow = new MainWindow(); var mainWindowViewModel = new MainWindowViewModel(); mainWindow.DataContext = mainWindowViewModel; LoadWindowSettings(mainWindow); mainWindow.Closed += MainWindow_Closed; mainWindow.Loaded += MainWindow_Loaded; mainWindow.ShowDialog(); }
protected override void OnStartup(StartupEventArgs z) { if (!File.Exists("Data\\KeycipherLicensing.db")) { var file = new FileInfo("Data\\KeycipherLicensing.db"); file.Directory.Create(); // If the directory already exists, this method does nothing. File.WriteAllBytes(file.FullName, ManagementApp.Properties.Resources.KeycipherLicensing); } AppDomain.CurrentDomain.FirstChanceException += (sender, e) => { var msg = new StringBuilder(); msg.AppendLine(e.Exception.GetType().FullName); msg.AppendLine(e.Exception.Message); var st = new StackTrace(); msg.AppendLine(st.ToString()); msg.AppendLine(); File.AppendAllText("errorlog.txt", msg.ToString()); ApplicationThemeHelper.UpdateApplicationThemeName(); }; base.OnStartup(z); }
protected override void OnStartup(StartupEventArgs e) { base.OnStartup(e); ApplicationThemeHelper.UpdateApplicationThemeName(); DbEngineDetector.PatchConnectionStringsAndConfigureEntityFrameworkDefaultConnectionFactory(); //var deleteContext = new DevAVDb(); //if(deleteContext.Database.Exists()) // deleteContext.Database.Delete(); var context = new DevAVDb(); if (!context.Database.Exists()) { DXSplashScreen.Show <GenerateDBSplashScreen>(); DXSplashScreen.SetState("Generating database..."); try { Database.SetInitializer <DevAVDb>(new DatabaseInitializer()); context.Customers.Count(); } finally { DXSplashScreen.Close(); } } }
private void OnAppStartup_UpdateThemeName(object sender, StartupEventArgs e) { ApplicationThemeHelper.UpdateApplicationThemeName(); }
private void OnAppStartup_UpdateThemeName(object sender, StartupEventArgs e) { ApplicationThemeHelper.UpdateApplicationThemeName(); DevExpress.Data.ShellHelper.TryCreateShortcut("mutest-notification", "NotificationService"); Trace.Listeners.Add(new EventLogTraceListener("MuTestUI")); }
protected override void OnStartup(StartupEventArgs e) { base.OnStartup(e); ApplicationThemeHelper.UpdateApplicationThemeName(); new Bootstrapper().Run(); }
public App() { ApplicationThemeHelper.UpdateApplicationThemeName(); }
private void Application_Startup(object sender, StartupEventArgs e) { ApplicationThemeHelper.UpdateApplicationThemeName(); DbEngineDetector.PatchConnectionStringsAndConfigureEntityFrameworkDefaultConnectionFactory(); }
protected override void OnStartup(StartupEventArgs e) { ApplicationThemeHelper.UpdateApplicationThemeName(); base.OnStartup(e); }
private void Application_Startup(object sender, StartupEventArgs e) { ApplicationThemeHelper.UpdateApplicationThemeName(); DbEngineDetector.PatchConnectionStringsAndConfigureEntityFrameworkDefaultConnectionFactory(); Database.SetInitializer <DepartmentContext>(new DepartmentContextInitializer()); }