FileSystemObject Property to determine if file is currently in use?

Dugantrain

I Love Pants
Local time
Today, 17:23
Joined
Mar 28, 2002
Messages
221
Is there a Method of the FileSystemObject class which will allow you to determine whether or not the file is currently in use (i.e. is open)?

*edit* if not, is there another class which could make this determination?
 
Last edited:
Dugantrain said:
Is there a Method of the FileSystemObject class which will allow you to determine whether or not the file is currently in use (i.e. is open)?

*edit* if not, is there another class which could make this determination?

Dugantrain,

The Filecopy command will not copy an open MS Office file (Excel, Word, Access); therefore you can use it and error trapping -- it returns error number 40 (I think) -- to determine if a file's open. It will, however, copy a text file that's open in Notepad.

Regards,
Tim
 
Well, it's actually a .txt file that I'm trying to get at. Either way, thanks for the reply, I'm sure that I can make use of it for future reference.
 
Last edited:

Users who are viewing this thread

Back
Top Bottom