filestat
Gets status information on a file or folder.
filestat <filename> <size> [<mtime>] [<drive>]
Remarks
Obtains information about the file or directory specified by <filename>.
<size> is set to the size of the file in bytes.
<mtime> is set to the time of last modification of file or folder.
<drive> is always set to '?' (this argument is for compatibility with Windows macros; a Mac has no drive letters).
The system variable "result" value of -1 indicates an error.
Example
filestat 'test.txt' size time drive if result = -1 then messagebox 'file open error' 'filestat' else sprintf2 str 'File size=%d Time modified=%s Drive=%s' size time drive messagebox str 'filestat' endif
filestat 'Macro' size time drive if result = -1 then messagebox 'Directory open error' 'filestat' else sprintf2 str 'Directory size=%d Time modified=%s Drive=%s' size time drive messagebox str 'filestat' ; ex. Directory size=0 Time modified=2014-03-04 22:44:47 Drive=? endif