Testing for File access

  • Thread starter Thread starter Phil S
  • Start date Start date
P

Phil S

When opening a file in two different threads at the same time, it will cause
an exception if the FileShare modes are incompatible with the FileAccess
modes.

Is there some way to test whether access will be allowed to the file without
having to try opening it and get an exception?
 
No, there is not, but why are the Fileshare modes incompatible if you need
to share file access?

Willy.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top