Windows Develop Bookmark and Share   
 index > Windows Forms General > share violation access on files in windows
 

share violation access on files in windows

how can i discard share violation access on files in windows in c#?
thanks
hassan azizi
MigrationUser 1  Friday, January 16, 2004 5:27 PM
I'm not exactly sure what you mean.

Are you saying that you are trying to open a file programatically and getting a Share Violation? 

When a file is opened, it can be set to share with these conditions:
- Share None - Exclusive Access. No one else will get to open the file.
- Share Read - Allow it to be opened if it is being opened for read-access only.
- Share Write - Allow it to only be opened for write.
- Share All - Allow anyone to open it.

If you are getting an error trying to open the file I would assume it is because someone has it open to share with None. Or they have it set to share with Read, and you are trying to open it for Write.



MigrationUser 1  Friday, January 16, 2004 6:45 PM

You can use google to search for other answers

Custom Search

More Threads

• DataGridView, ValueType, and Format
• regarding password protection
• Adding a control to the Operating System Window !!
• copy paste?
• Is it possible to open a form that will run on a different thread?
• Passing Value to the Crystal Report
• Treeview AfterSelect and TextBox Focus
• How to do like [My site on the MSN]???
• Rotation point
• How to close previously opened menu items from an MDI Form when a new menu item is clicked?