Change or show working directory
X-Function not designed for Auto GetN Dialog.
1. cd;
2. cd newpath:=c:\c\proj1;
3. cd newpath:="c:\my proj-1";
4. cd result:=aa;
5. cd newpath:="c:\my proj1" result:=aa;
6. cd newpath:="" result:=aa;
Please refer to the page for additional option switches when accessing the x-function from script
Display Name |
Variable Name |
I/O and Type |
Default Value |
Description |
---|---|---|---|---|
newpath |
Input string |
|
This folder will become the new working directory. Double quotes are required if the path has a space or dash in it. To clear working directory, use empty path in double quotes "". If newfolder is not defined, the current working folder is displayed and refreshed. | |
result |
Output string |
|
Outputs the working directory into a string variable. cd result:=aa puts working directory into variable aa$. aa$ now stores the working directory. |
This X-Function is used to change or show working directory
To refresh and show working directory, use the following command:
cd
To set c:\c\proj1 as working directory, use the following command:
cd c:\c\proj1
To use quotes if path has space or dash, use the following command:
cd "c:\my proj-1"
To get the working directory into string variable aa$, use the following command:
cd result:=aa
To set working directory and get it into string variable aa$, use the following command:
cd "c:\my proj1" aa
To set working directory to empty, and also set aa$ to empty, use the following command:
cd "" aa