Re: Read a file locked by another program
- From: Tom Esh <tjeshGibberish@xxxxxxxxxx>
- Date: Thu, 02 Mar 2006 00:52:38 -0500
On 1 Mar 2006 21:31:47 -0800, "Rajat" <garbagea@xxxxxxxxx> wrote:
I was refering to the FileOpen function in VB.NET.
I tried opening the file as a TextStream.
Both of them failed. Presumably because of the reason you state. The
creating application did not allow it to be shared.
There has to be a way around this because Textpad and even Notepad can
open these files.
If Textpad and Notepad can open it, then the creating process is
allowing shared read access. As Thorsten noted, the problem is your
app is requesting write and/or ~exlusive read~ access when it should
only be requesting read. Normal VB provides this capability, so
presumably .Net does as well, but you need to ask .Net questions in
one of the .Net groups.
-Tom
MVP - Visual Basic
(please post replies to the newsgroup)
.
- References:
- Re: Read a file locked by another program
- From: Rajat
- Re: Read a file locked by another program
- Prev by Date: Re: Read a file locked by another program
- Next by Date: Negative File size ??
- Previous by thread: Re: Read a file locked by another program
- Next by thread: Re: Read a file locked by another program
- Index(es):
Relevant Pages
|