PATH.Up |
folder = PATH.Up( path AS STRING ) AS STRING
Returns the path that is above the specified path. For example, the path D:\TECH\PROJECTS would return D:\TECH. Note that the path may contain a filename and in that case it will return the folder above the filename location.
Example:
OPTION TRACE ON
$INCLUDE "MyBASIC2_ExtLib" $LIBRARY "MyBASIC2_ExtLib"
DIM strExe AS STRING
' Execute the file with the same name in the folder above this script
strExe = PATH.Up( PATH.Split( FILENAME, EL_Drive + EL_Directory ) ) +_ PATH.Split( FILENAME, EL_Filename ) + ".EXE"
SHELL.Execute( strExe, )
END
|