Home All Groups Group Topic Archive Search About

FindFirstFile/FindNextFile - fastest alternative?

Author
6 Oct 2006 10:19 PM
technodwebe
If you're trying to create a fast file find function that will work in
both XP-32 and XP-64, what method would you use?

Author
7 Oct 2006 1:11 AM
Michael D. Ober
Are you handling one file at a time or will a collection of files be
sufficient.  If it's one at a time, take a look at the VB legacy "dir"
statement and function.  If a collection will suffice, take a look at the
system.io.directory namespace.

Mike Ober.

Show quoteHide quote
"technodwebe" <google-groups.20.technodw***@xoxy.net> wrote in message
news:1160173149.056887.170320@i3g2000cwc.googlegroups.com...
> If you're trying to create a fast file find function that will work in
> both XP-32 and XP-64, what method would you use?
>
>
Author
7 Oct 2006 12:53 PM
Herfried K. Wagner [MVP]
"technodwebe" <google-groups.20.technodw***@xoxy.net> schrieb:
> If you're trying to create a fast file find function that will work in
> both XP-32 and XP-64, what method would you use?

Depending on the exact situation I'd recursively call
'System.IO.Directory.GetFiles'.

--
M S   Herfried K. Wagner
M V P  <URL:http://dotnet.mvps.org/>
V B   <URL:http://dotnet.mvps.org/dotnet/faqs/>
Author
8 Oct 2006 3:39 PM
vb newbie
Thanks!  That worked really well.  It's a lot slower than the API, but
you use whatcha got   :)

Herfried K. Wagner [MVP] wrote:
Show quoteHide quote
> "technodwebe" <google-groups.20.technodw***@xoxy.net> schrieb:
> > If you're trying to create a fast file find function that will work in
> > both XP-32 and XP-64, what method would you use?
>
> Depending on the exact situation I'd recursively call
> 'System.IO.Directory.GetFiles'.
>
> --
>  M S   Herfried K. Wagner
> M V P  <URL:http://dotnet.mvps.org/>
>  V B   <URL:http://dotnet.mvps.org/dotnet/faqs/>