private void MenuMainFileNewProjectClick(object sender, EventArgs e) { try { if (!CreateNewProject()) { return; } solutionExplorer.SetSolution(_solution); solutionExplorer.Refresh(); _recentSolutions.Add(_solution.FileSystemPath); FileUtility.AddToRecentDocuments(_solution.FileSystemPath); } catch (Exception ex) { MessageEngine.ShowError(ex); } }
public void OpenSolutionWorker(string fileSystemPath) { try { CloseSolution(); _solution = CrcsSolution.OpenSolution(fileSystemPath); solutionExplorer.SetSolution(_solution); solutionExplorer.Refresh(); solutionExplorer.ExpandTreeNodes(_solution.PathsForExpandedTreeNodes); _solution.OpenRememberdFiles(OpenFile); _recentSolutions.Add(fileSystemPath); FileUtility.AddToRecentDocuments(fileSystemPath); menuMainViewShowExcluded.Checked = _solution.ShowExcludedItems; SetTitle(); } finally { if (_loadSolutionDlg != null) { _loadSolutionDlg.Close(); _loadSolutionDlg = null; } } }