Results 1 to 1 of 1

Thread: How to check a folder exists (solved)

Threaded View

  1. #1

    Thread Starter
    New Member
    Join Date
    Jul 2002
    Posts
    13

    How to check a folder exists (solved)

    I am trying to check that a network folder exists (i.e. \\computername\folder\subfolder). I am currently using the following code:

    VB Code:
    1. If (Dir$(sFilePath & "\nul") <> "") = True Then
    2.     ' Folder Exists
    3. else
    4.      'Folder not found
    5. end if


    This seems to work for mapped drives etc. However it doesn't work on UNC's

    The fix for this is to take the & "\nul" out of the check.
    Last edited by toffeeman; Oct 23rd, 2003 at 03:55 AM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width