470,632 Members | 1,333 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 470,632 developers. It's quick & easy.

File System Watcher question. about create event

I have a file system watcher.
It is watching one directory where faxes come in.

These faxes are written by another software program.

The create event seems to fire and then we get an error trying to move this
to another folder because it says it is in use by another process.

I imagine that the fax software opens it, and starts writing but doesn't
close it, then the
FileSystemWatcher, fires create event before the file is closed and we get
the error, the it probably closes.

If we put a 15 second pause in before moving the file, it works, but this is
only a temporary fix as if it took longer that 15seconds for them to write a
big fax, it would again fail.

Is there a better solution? Is there a way to only get the event if the
file is closed?

Or should we somehow check if the file is closed? How? Before moving it?

Thanks for any ideas.
Nov 21 '05 #1
0 893

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

3 posts views Thread by Ron Vecchi | last post: by
7 posts views Thread by Allen Anderson | last post: by
reply views Thread by Jack David | last post: by
2 posts views Thread by Jack David | last post: by
5 posts views Thread by ToddT | last post: by
1 post views Thread by Stuart Ferguson | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.