SMB1.ListFiles(FInfo.WD.SubString2(0, FInfo.WD.LastIndexOf2("/", FInfo.WD.Length - 2) + 1), FInfo.WD.SubString2(FInfo.WD.LastIndexOf2("/", FInfo.WD.Length - 2) + 1, FInfo.WD.Length - 1))
Wait For SMB1_ListCompleted (Url As String, Success As Boolean, Entries() As SMBFile)
If Not(Success) Then
FInfo.LD = "Unable to find our network directory " & FInfo.WD.SubString(4) & ". This may be due to an invalid directory, bad username/password, or inadequate rights."
Return
Else
SMB1.ListFiles(FInfo.WD, FInfo.WF)
Wait For SMB1_ListCompleted (Url As String, Success As Boolean, Entries() As SMBFile)
Log(Success)
Log(LastException)
Log (Entries.Length)
If Success Then
If Entries.Length > 0 Then
FInfo.LD = "This file already exists! You are not allowed to overwrite existing files."
Return
End If
End If
End If