Beispiel #1
0
        private void OpenDBPathDialog()
        {
            var manager = new DatabasePathManager();
            var dialog  = new DatabasePathDialog(manager);

            if (dialog.ShowDialog() == true)
            {
                System.Diagnostics.Process.Start(Application.ResourceAssembly.Location);//restart
            }
            Application.Current.Shutdown();
        }
 public DatabasePathDialog(DatabasePathManager databasePathManager)
 {
     InitializeComponent();
     DataContext = databasePathManager;
     databasePathManager.OnExit = () => { DialogResult = true; Close(); };
 }