$return = FileStat(filename,mode)
|$return||is the integer return code for one of the following standard Windows file exceptions: |
0 = none. No error occurred.
1 = genericException. An unspecified error occurred.
2 = fileNotFound. The file could not be located.
3 = badPath. All or part of the path is invalid.
4 = tooManyOpenFiles. The permitted number of open files was exceeded.
5 = accessDenied. The file could not be accessed.
6 = invalidFile. There was an attempt to use an invalid file handle.
7 = removeCurrentDir. The current working directory cannot be removed.
8 = directoryFull. There are no more directory entries.
9 = badSeek. There was an error trying to set the file pointer.
10 = hardIO. There was a hardware error.
11 = sharingViolation. SHARE.EXE was not loaded, or a shared region was locked.
12 = lockViolation. There was an attempt to lock a region that was already locked.
13 = diskFull. The disk is full.
14 = endOfFile. The end of file was reached.
|filename||is the full filename, including drive letter and path name for the file.|
|mode||is the mode of the open request. It must be one of the following.|
path and mode may be a variables.
The FileStat command returns the status from an open request to a disk file.
If FileStat("D:\test.txt",modeRead) = 2 Then GoTo FileNotFound:
If FileStat("D:\test.txt",modeWrite) = 11 Then GoTo FileAlreadyOpen:
TN3270 Plus is continually being improved. To learn more about the latest enhancements, please review our Version History web page.