Determining whether a path exists : Path « File Path « VBA / Excel / Access / Word






Determining whether a path exists

 
Function PathExists(pname) As Boolean
    Dim x As String
    On Error Resume Next
    x = GetAttr(pname) And 0
    If Err = 0 Then PathExists = True _
      Else PathExists = False
End Function

 








Related examples in the same category

1.Get the Path Separator
2.Get file name from a path name