VBScript - Expected Loop

By AlAckley ·
I've a little script that checks for the existence of a file share and if it exists checks for the most recent file. I'm running into an expected Loop error within one area of the code and am hoping someone can give me a hand. The error appears after the If statement starts but before the Else. I tried adding a Loop prior to the Else but that gave a syntax error.

Do Until objFile.AtEndOfStream
shelfPath = objFile.ReadLine
i = i + 1
WshNetwork.MapNetworkDrive driveLetter, shelfPath
If Err.Number <> 0 Then objCreateFile.Write(shelfPath + " can't be reached")
call checkShelf
End If

This conversation is currently closed to new comments.

3 total posts (Page 1 of 1)  
| Thread display: Collapse - | Expand +


Collapse -
by danekan

what is objCreateFile? not enough info provided by you, or perhaps the obvious problem if this is your complete script is you haven't defined objCreateFile.

All Answers

Back to Software Forum
3 total posts (Page 1 of 1)  

Related Discussions

Related Forums