String chooseArchiveFile(String approveButtonText, String approveToolTip) {

		GhidraFileChooser jarFileChooser =
			createFileChooser(ArchivePlugin.ARCHIVE_EXTENSION, "Ghidra Archives", archivePathName);
		jarFileChooser.setTitle("Restore a Ghidra Project - Archive");
		String lastDirSelected = Preferences.getProperty(ArchivePlugin.LAST_ARCHIVE_DIR);
		if (lastDirSelected != null) {
			File dir = new File(lastDirSelected);
			if (dir.isDirectory()) {
				jarFileChooser.setCurrentDirectory(dir);
			}
		}
		File jarFile = null;
		if (archivePathName != null && archivePathName.length() != 0) {
			jarFile = new File(archivePathName);
		}
		jarFileChooser.setSelectedFile(jarFile);
		jarFileChooser.setApproveButtonText(approveButtonText);
		jarFileChooser.setApproveButtonToolTipText(approveToolTip);

		String pathname = null;
		while (pathname == null) {
			File selectedFile = jarFileChooser.getSelectedFile();

			if (selectedFile == null) {
				return null; // user cancelled, get out
			}

			File file = selectedFile;
			String chosenName = file.getName();
			if (!NamingUtilities.isValidProjectName(chosenName)) {
				Msg.showError(getClass(), null, "Invalid Archive Name",
					chosenName + " is not a valid archive name");
				continue;
			}

			Preferences.setProperty(ArchivePlugin.LAST_ARCHIVE_DIR, file.getParent());
			pathname = file.getAbsolutePath();
		}

		jarFileChooser.dispose();

		return pathname;
	}
Brings up a file chooser for the user to specify a directory and
filename that are used for the Project location and name
@param approveButtonText The label for the "Open" button on the file chooser
@param approveToolTip The tool tip for the "Open" button on the file chooser
@return the archive file path.
Ghidra/Features/Base/src/main/java/ghidra/app/plugin/core/archive/RestoreDialog.java