// -- Public methods -- public bool LoadPuzzleFromFile(string filename) { // Create the streamReader try { using (StreamReader reader = new StreamReader(filename)) { // Load the puzzle this.puzzleBoard = PuzzleBoard.FromString(reader.ReadToEnd()); this.puzzleBoard.EditorMode = Settings.Get.EditorMode; this.OnResize(); this.updateTitleBar(filename); return(true); } } catch { this.showMessage("There was an error loading the puzzle.", "Loading", StatusIcon.Error); return(false); } }