/// /// <summary> /// Exports IP addresses of a project to file. /// </summary> private void exportIPFile() { if (_strTabIndex != "") { SaveFileDialog saveFileDialog = new SaveFileDialog(); //Creates SaveFileDialog saveFileDialog.Title = "Export IP Addresses"; saveFileDialog.Filter = ".txt|*.txt"; //Only allows the user to save the file type as .sav saveFileDialog.ShowDialog(); //Displays dialog if (saveFileDialog.FileName != "") { bool saveStatus = _proInter.exportIPs(_strTabIndex, saveFileDialog.FileName); if (saveStatus == false) { MessageBox.Show("An error has occurred during the export process.", "Export Unsuccessful", MessageBoxButtons.OK, MessageBoxIcon.Error); } } } }