R: A select directory dialog box

dlgDir {svDialogs} | R Documentation

## A select directory dialog box

### Description

Allows to easily select a directory.

### Usage

    dlgDir(default = getwd(), title, ..., gui = .GUI)

    ## These should not be called directly
    ## S3 method for class 'gui'
    dlgDir(default = getwd(), title, ..., gui = .GUI)
    ## S3 method for class 'textCLI'
    dlgDir(default = getwd(), title, ..., gui = .GUI)
    ## S3 method for class 'nativeGUI'
    dlgDir(default = getwd(), title, ..., gui = .GUI)

### Arguments

`default` | the directory to start with.
`title` | a title to display on top of the dialog box.
`...` | pass further arguments to methods.
`gui` | the 'gui' object concerned by this dialog box.

### Value

The modified 'gui' object is returned invisibly. The choosen directory, or an empty string if the cancel button was clicked is found in `gui$res` (see example).

### Author(s)

Philippe Grosjean (phgrosjean@sciviews.org)

### See Also

`dlgOpen`, `dlgSave`

### Examples

    ### A quick default directory changer
    setwd(dlgDir(default = getwd())$res)

[Package svDialogs version 0.9-57 Index]