Use the --file-selection option to create a file selection dialog.  returns the selected files or directories to standard
error. The default mode of the file selection dialog is open.
The file selection dialog supports the following options:
--filename=filenameSpecifies the file or directory that is selected in the file selection dialog when the dialog is first shown.--multipleAllows the selection of multiple filenames in the file selection dialog.--directoryAllows only selection of directories in the file selection dialog.--saveSet the file selection dialog into save mode.--separator=separatorSpecifies the string that is used to divide the returned list of filenames.
The following example script shows how to create a file selection dialog:
#!/bin/sh
FILE=`zenity --file-selection --title="Select a File"`
case $? in
0)
echo "\"$FILE\" selected.";;
1)
echo "No file selected.";;
-1)
echo "No file selected.";;
esac
file selection dialog example
