private void openbutton_Click(object sender, EventArgs e) { if (open.ShowDialog() == DialogResult.OK) { openFile = open.selectedSet; openFile.loadFile(); populate(); saveToolStripMenuItem.Enabled = false; } }
/// <summary> /// Import a SlideSet into the program's folder using an existing .sld file. /// </summary> /// <param name="path">The full path to the .sld file to import.</param> /// <returns>Returns an ErrorCode specifying what went wrong during the import.</returns> public static ImporterErrorCode importSLD(string path) { try { iss = new EditableSlideSet(path); iss.loadFile(); iss.resetPath(); } catch (Exception e) { //Program.ReportError(e); return(ImporterErrorCode.GenericError); } return(ImporterErrorCode.CompletedSucessfully); }