daillest319
Programmer
I'm trying to write a script to check a files date and time so i know its ready to upload. I'm not sure what im doing wrong but i need to check if the file is greater than 10:00AM and also greater than yest date.
Code:
Dim objFS, strFile
Set objFS = CreateObject("Scripting.FileSystemObject")
strFile = "C:\TEST\test.txt"
if objFS.GetFile(strFile).DateLastModified > date - 1 & "10:00:00 AM" then
WScript.Echo "Upload is ready"
else
WScript.Echo "Upload is not ready"
end if