Home All Groups Group Topic Archive Search About

Issues with Streamwriter class

Author
21 Dec 2005 6:03 AM
Mohit
Iam using streamwriter class of .net to write in  a file. The location of
file is a network drive. Now if for some reason the network is not there
and I execute
                    sw.close I get a exception ( that's ok).
But later when network comes and I try to delete this file, it says that the
file is being used by a process. How to release the file handle in such a
case.

Thanks,
Mohit

Author
22 Dec 2005 5:25 AM
Lloyd Dupont
hehe, I remember now that I already see that error.
as I rememeber there was no solution (but I'm not quite sure to remember
correctly)

--
Regards,
Lloyd Dupont

NovaMind development team
NovaMind Software
Mind Mapping Software
<www.nova-mind.com>
Show quote
"Mohit" <Mo***@discussions.microsoft.com> wrote in message
news:CB40091C-E413-428D-B2B9-848F69E9573F@microsoft.com...
> Iam using streamwriter class of .net to write in  a file. The location of
> file is a network drive. Now if for some reason the network is not there
> and I execute
>                    sw.close I get a exception ( that's ok).
> But later when network comes and I try to delete this file, it says that
> the
> file is being used by a process. How to release the file handle in such a
> case.
>
> Thanks,
> Mohit
>

AddThis Social Bookmark Button