MAINSAIL Language Manual, Section 47.10

previous   next   top   contents   index   framed top   this page unframed


47.10. $setCurrentDirectory

Figure 47–12. $setCurrentDirectory
BOOLEAN
PROCEDURE   $setCurrentDirectory
                        (
STRING directoryName;
                         
OPTIONAL BITS ctrlBits;
                         
PRODUCES OPTIONAL STRING msg);

$setCurrentDirectory sets the current directory to directoryName. If directoryName includes a device prefix, then the current directory for that device is set; otherwise, the current directory for the default disk device (i.e., the operating system's file system) is set. The device prefix, if present, should be prepended to the directory name and separated from it by the STRING $devModBrkStr. For example, if $devModBrkStr is ">" and the directory xxx/yyy is to become the current directory for a device MODULE D, directoryName should be "D>xxx/yyy".

$setCurrentDirectory returns TRUE on success, FALSE on failure. If it fails, msg is set to an error message describing the failure.

Valid ctrlBits bits for $setCurrentDirectory are errorOK and $useOriginalFileName. If errorOK is set, then errMsg is not called when $setCurrentDirectory fails. If $useOriginalFileName is set, no logical file name or file searchpath substitution is performed on directoryName.

The interface of $setCurrentDirectory is subject to improvement if it proves unsatisfactory.


previous   next   top   contents   index   framed top   this page unframed

MAINSAIL Language Manual, Section 47.10