Wilson WindowWare Tech Support

WinBatch WinBatch+Compiler WebBatch
Home | Tech Database | Tech BBS | White Papers | Purchase


FileExist Returns Sharing Violation

Keywords:	 FileExist File Exist article

Problem:

FileExist returns "2" if the specified file exists but is currently open by another application in read deny mode. If you try to access this file using (most of) the other "File..." functions, it will cause a sharing violation.

The solution is to use the FileItemize function instead, as in:

 If FileItemize(filename) == "" Then ...

Article ID:   W13067
Filename:   FileExist Returns Sharing Violation.txt