| setwdGUI {PBSmodelling} | R Documentation |
Allows the user to browse a directory tree to set the working directory. Optionally, files with given suffixes can be located in the new directory.
setwdGUI(suffix)
suffix |
character vector of suffixes or "" (See Details). |
The suffix argument is passed to a call to
findPrefix after the working directory is changed
(See setwd). If suffix is set to the empty
string "", then findPrefix will not be called.
To use this function in a window description file,
the suffix argument must be specified as the action of
the widget that calls setwdGUI. Furthermore, the
suffixes must be separated by commas (e.g., action=.c,.cpp).
If action=, is specified, then findPrefix will not be called.
If suffixes are given, a character vector of prefixes of all files in
the working directory that match one of the given suffixes is returned;
otherwise, the function returns invisible().
If all the required arguments are missing, it is assumed that the function is being called by a GUI widget.
## Not run:
#match files that end with ".a" followed by 0 or more characters, ".b" followed
#by any single character, ".c", or "-old.d" (a suffix does not have to be a
#file extension)
findPrefix(".a*", ".b?", ".c", "-old.d")
## End(Not run)