guitarzan,
Thank you for the quick reply. But I am not understanding how:
Set objFolder = objFSO.GetFolder("C:\temp")
For Each objFile in objFolder.Files
If LCase(Right(objFile.Path, 4)) = ".txt" Then
'do something
End If
Next
Replaces:
Set objFile =...
I need a little help with this vbs script. The script works great but I want to be able to open any file that is in the folder without having to give the exact name of the file.
Here is the script:
Const ForReading = 1
Const ForWriting = 2
Set objFSO =...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.