public File openFile(String currentValue, String text, String extension) {
		JFileChooser chooser = null;
		if (currentValue != null) {
			String file = StaticValues.resourceToFile(currentValue);
			if (file != null) {
				File ffile = new File(file).getParentFile();
				chooser = new JFileChooser(ffile);
			}
		}
		if (chooser == null) {
			if (StaticValues.config.technicalFile != null) {
				chooser = new JFileChooser(new File(StaticValues.config.technicalFile).getParentFile());
			} else {
				chooser = new JFileChooser(System.getProperty("user.dir"));
			}
		}
		if (extension != null) {
			FileExtensionFilter filter = new FileExtensionFilter(extension, text);
			chooser.setFileFilter(filter);
		}
		chooser.setDialogTitle(text);
		if (extension == null) {
			if (chooser.showSaveDialog(this) == JFileChooser.APPROVE_OPTION) {
				return chooser.getSelectedFile();
			}
		} else {
			if (chooser.showOpenDialog(this) == JFileChooser.APPROVE_OPTION) {
				return chooser.getSelectedFile();
			}
		}
		return null;
	}