Thanks Silky and Bill

I was just going to isolate my code in a small standalone application just 
prior to reading your missive.

I thought their might be some lock in place but I only use this code in one 
place.
The method is static. There is no means to close, shutdown or release anything 
that I could find.

Hmmmn, That made me think. This is a project that was started by someone else.

I just noticed they had (although they might deny it now that I have been 
working on it).

                originalFileName = String.Empty;
                using (var csv = new CsvReader(new StreamReader(fileName), 
true, Delimitor))
                {

That does not look right. The filestream will never be closed (at least I don't 
think so)

I have changed this to 

            originalFileName = String.Empty;
            // open the file. It is expected to be a CSV file with headers
            using (var sr = new StreamReader(fileName))
            {
                using (var csv = new CsvReader(sr, true, Delimitor))
                {

I will try this out after another reboot.

I will also try out the Directory.GetLogicalDrives();
If the above does not achieve anything.


Regards Peter Maddin
Applications Development Officer
PathWest Laboratory Medicine WA
Phone : +618 9473 3944
Fax : +618 9473 3982
E-Mail : [email protected]
The contents of this e-mail transmission outside of the WAGHS network are 
intended solely for the named recipient's), may be confidential, and may be 
privileged or otherwise protected from disclosure in the public interest. The 
use, reproduction, disclosure or distribution of the contents of this e-mail 
transmission by any person other than the named recipient(s) is prohibited. If 
you are not a named recipient please notify the sender immediately.




-----Original Message-----
From: [email protected] [mailto:[email protected]] On 
Behalf Of silky
Sent: Tuesday, 18 May 2010 1:26 PM
To: ozDotNet
Subject: Re: DriveInfo.GetDrives() not returning

On Tue, May 18, 2010 at 1:53 PM, Maddin, Peter
<[email protected]> wrote:

[...]

> I am targeting .NET 3.5. Is it a framework problem, driver problem, some
> other problem?
>
> Could it just be the machine I am using?

I know its boring but can you reproduce it in a stand-alone app? (not
part of your main one?)

My guess would be you're somehow in a lock with yourself.


> Regards Peter Maddin
> Applications Development Officer
> PathWest Laboratory Medicine WA
> Phone : +618 9473 3944
> Fax : +618 9473 3982
> E-Mail : [email protected]
> The contents of this e-mail transmission outside of the WAGHS network are
> intended solely for the named recipient's), may be confidential, and may be
> privileged or otherwise protected from disclosure in the public interest.
> The use, reproduction, disclosure or distribution of the contents of this
> e-mail transmission by any person other than the named recipient(s) is
> prohibited. If you are not a named recipient please notify the sender
> immediately.

-- 
silky

  http://www.programmingbranch.com/

Reply via email to