private void mainFolderToolStripMenuItem_Click(object sender, EventArgs e) { var dialog = new SelectMovieFolder(); if (dialog.ShowDialog() == DialogResult.OK) { Settings.Default.baseDir = dialog.GetSelectedFolder(); baseDir = dialog.GetSelectedFolder(); Settings.Default.Save(); } }
private void Form1_Shown(object sender, EventArgs e) { bool noBaseDir = baseDir == "" || !Directory.Exists(baseDir); if (noBaseDir) { var dialog = new SelectMovieFolder(); if (dialog.ShowDialog() == DialogResult.OK) { Properties.Settings.Default.baseDir = dialog.GetSelectedFolder(); Properties.Settings.Default.Save(); baseDir = dialog.GetSelectedFolder(); } } getDirs(baseDir); currentDir = baseDir; }