By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
459,299 Members | 1,247 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 459,299 IT Pros & Developers. It's quick & easy.

DirectoryInfo.GetFiles

P: n/a
Hey Everyone,

Sorry haven't been around to answer questions as much as usual (or at all
for that matter) just been engrossed in a project. Anyways, dealing with an
issue using DirectoryInfo.GetFiles wondering if anyone had the same issues

I built my function to get the files, using a searchPattern filter (*.tif)
in which case I have about a gig of files in this directory (about 5000
files) and using getFiles is slower than anything I have ever seen. There
isn't a standard Async invoke on it so I was wondering if anyone else got
around this problem using the .NET Framework.

Basically it takes about 2 minutes to read dir info.

Thanks,
CJ
Nov 20 '05 #1
Share this Question
Share on Google+
5 Replies


P: n/a
Cor
Hi CJ,

Nice to see you, I saw a Taylor in the Ado.Net group and thought it was you.

I did test it, but with a directory with more than 5000 files this was not
slow for me.
\\\
Dim di As DirectoryInfo = New DirectoryInfo("c:\Taylor")
Dim fils As FileInfo() = di.GetFiles("*.*")
Dim i As Integer
Dim fiNext As FileInfo
For Each fiNext In fils
i += 1
Next
Me.TextBox1.Text = i.ToString
///
Cor
Sorry haven't been around to answer questions as much as usual (or at all
for that matter) just been engrossed in a project. Anyways, dealing with an issue using DirectoryInfo.GetFiles wondering if anyone had the same issues

I built my function to get the files, using a searchPattern filter (*.tif)
in which case I have about a gig of files in this directory (about 5000
files) and using getFiles is slower than anything I have ever seen. There
isn't a standard Async invoke on it so I was wondering if anyone else got
around this problem using the .NET Framework.

Nov 20 '05 #2

P: n/a
Ahhh and over a network.....

that could be it...
"Cor" <no*@non.com> wrote in message
news:u3**************@TK2MSFTNGP12.phx.gbl...
Hi CJ,

Nice to see you, I saw a Taylor in the Ado.Net group and thought it was you.
I did test it, but with a directory with more than 5000 files this was not slow for me.
\\\
Dim di As DirectoryInfo = New DirectoryInfo("c:\Taylor")
Dim fils As FileInfo() = di.GetFiles("*.*")
Dim i As Integer
Dim fiNext As FileInfo
For Each fiNext In fils
i += 1
Next
Me.TextBox1.Text = i.ToString
///
Cor
Sorry haven't been around to answer questions as much as usual (or at all for that matter) just been engrossed in a project. Anyways, dealing with
an
issue using DirectoryInfo.GetFiles wondering if anyone had the same

issues
I built my function to get the files, using a searchPattern filter (*.tif) in which case I have about a gig of files in this directory (about 5000
files) and using getFiles is slower than anything I have ever seen. There isn't a standard Async invoke on it so I was wondering if anyone else got around this problem using the .NET Framework.


Nov 20 '05 #3

P: n/a
Hey Cor,

Good to hear from you, what kind of file where you using? What was your
average file size. I'm wondering what is going on or if its an issue with
reading these tif files (which some are large)

-CJ
"Cor" <no*@non.com> wrote in message
news:u3**************@TK2MSFTNGP12.phx.gbl...
Hi CJ,

Nice to see you, I saw a Taylor in the Ado.Net group and thought it was you.
I did test it, but with a directory with more than 5000 files this was not slow for me.
\\\
Dim di As DirectoryInfo = New DirectoryInfo("c:\Taylor")
Dim fils As FileInfo() = di.GetFiles("*.*")
Dim i As Integer
Dim fiNext As FileInfo
For Each fiNext In fils
i += 1
Next
Me.TextBox1.Text = i.ToString
///
Cor
Sorry haven't been around to answer questions as much as usual (or at all for that matter) just been engrossed in a project. Anyways, dealing with
an
issue using DirectoryInfo.GetFiles wondering if anyone had the same

issues
I built my function to get the files, using a searchPattern filter (*.tif) in which case I have about a gig of files in this directory (about 5000
files) and using getFiles is slower than anything I have ever seen. There isn't a standard Async invoke on it so I was wondering if anyone else got around this problem using the .NET Framework.


Nov 20 '05 #4

P: n/a
Cor
> Ahhh and over a network.....

that could be it...

Hi CJ,

That you did not say :-))

Cor
Nov 20 '05 #5

P: n/a
Yeah... I'm always forgetting little "mundane" details like that...

and decimal points...

(I will answer any question in the world if somoene actually gets that
reference.)

-CJ
"Cor" <no*@non.com> wrote in message
news:eh**************@tk2msftngp13.phx.gbl...
Ahhh and over a network.....

that could be it...

Hi CJ,

That you did not say :-))

Cor

Nov 20 '05 #6

This discussion thread is closed

Replies have been disabled for this discussion.