Using the %currentlocaldir Variable

Top  Previous  Next

 

The current local working folder FTPPWDis maintained in an internal variable named %currentlocaldir.

 

WORKINGDIR "c:\temp"

DISPLAY %currentlocaldir

 

Whenever changing the working folder in script functions or called scripts, it is recommended that the original working folder always be restored prior to returning as shown in the following sample code.FTPPWD

 

FUNCTION things todo

;; save current working folder

SET savdir = %currentlocaldir

;; do whatever...

WORKINGDIR "c:\temp"

;; ...

;; restore working folder

WORKINGDIR savdir

RETURN