Re: What should DIR("") return?

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance



I believe I understand what was happening now.
I could work around it, but it became futher complicated by the use of
UNC paths, in that errors would arise when checking for the BackEnd
data. I am now using the following code which resolved the matter,
and have further included a less responsive error handler.

If GetAttr(strFileName) And vbDirectory Then
'it's a directory or does not exist
FileExists = False
Else
FileExists = True
End If
On Error GoTo 0

ThankYou
Greg

.



Relevant Pages

  • Re: searching a file
    ... I want to search a file in some specified directory. ... expecting is whether the file exists in that particular directory or not. ... If And vbDirectory) vbDirectory Then ... FileExists = False ...
    (microsoft.public.vb.syntax)
  • Re: searching a file
    ... expecting is whether the file exists in that particular directory or not. ... If And vbDirectory) vbDirectory Then ... FileExists = False ... Rick ...
    (microsoft.public.vb.syntax)
  • Re: unc file spec ?????
    ... rob merritt wrote: ... > unfortunatly looks like fileexists doesn't work with UNC paths ... -- torgeir, Microsoft MVP Scripting and WMI, Porsgrunn Norway Administration scripting examples and an ONLINE version of the 1328 page Scripting Guide: ...
    (microsoft.public.scripting.wsh)
  • Re: check if file exists
    ... On Error GoTo FileExists_Error ... FileExists = False ... Dim x As String ...
    (microsoft.public.excel.programming)
  • Problem with path
    ... I am having some problems with UNC paths. ... and this path is actually the local computer my program is running on, ... FileExists returns false for this path. ... I am using D5Pro on WinXP. ...
    (borland.public.delphi.nativeapi)