Re: Invalid procedure call or argument - Dir function

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance



On Wed, 17 Jan 2007 15:50:43 -0800, "Karl E. Peterson" <karl@xxxxxxxx>
wrote:

guy_jara@xxxxxxxxx wrote:
Takeaway: It would appear that long periods of time between calls to
the Dir function causes it to loose "reference," if you will, to the
previously initialized search pattern, and moreover, to the function
itself.

That's an incredibly interesting observation! One that could be tested,
empirically, were one wanting to. It infers that VB is calling FindClose after some
set period of elapsed time. Hmmmmm....

Actually it 'implies' - sorry for being a nit picker
- I once got it in the neck, and try to prevent others getting tripped
up
( Another Delphi version of ForceFore posted today :-} )

My gut instinct hinges on the word WAN

The acid test would be using FindFirstFile, I suspect that Dir() is a
very thin wrapper.

The OP has done the smart thing
Pre-preparing data is the way to go
- and avoiding Dir outside tight (small) loops helps one stay sane

.



Relevant Pages

  • Re: Invalid procedure call or argument - Dir function
    ... the Dir function causes it to loose "reference," if you will, to the ... previously initialized search pattern, and moreover, to the function ... ..NET: It's About Trust! ...
    (microsoft.public.vb.general.discussion)
  • Re: Invalid procedure call or argument - Dir function
    ... the Dir function causes it to loose "reference," if you will, to the ... previously initialized search pattern, and moreover, to the function ... It infers that VB is calling FindClose after ...
    (microsoft.public.vb.general.discussion)
  • Re: Invalid procedure call or argument - Dir function
    ... the Dir function causes it to loose "reference," if you will, to the ... previously initialized search pattern, and moreover, to the function ... calling FindClose after some set period of elapsed time. ...
    (microsoft.public.vb.general.discussion)
  • Re: Invalid procedure call or argument - Dir function
    ... the Dir function causes it to loose "reference," if you will, to the ... previously initialized search pattern, and moreover, to the function ... calling FindClose after some set period of elapsed time. ...
    (microsoft.public.vb.general.discussion)
  • Re: Lost me job...what now?
    ... redundant face to face, they feel for your situation, hell it could be them ... shake on it. ... say and I want a damned good reference as well. ... What you got to loose? ...
    (uk.gov.agency.csa)