Could someone please assist with my script below. Im pretty certain my use of the IF.. Then is incorrect, Im new to scripting so still trying to get to grips with the Syntax issues. Im trying to check for any File of Size 0 with a specific local folder. Any help much appreicated:
Function TestFileSizeOf0InFolder
Dim fso, fo, fc, f
set fso = CreateObject("Scripting.FileSystemObject")
set fo = fso.GetFolder("c:\testfolder\")
set fc = fo.Files
set f = fc.FileSize
If f=("0") Then
WScript.Echo "File Found"
Else
End If
End Function
Function TestFileSizeOf0InFolder
Dim fso, fo, fc, f
set fso = CreateObject("Scripting.FileSystemObject")
set fo = fso.GetFolder("c:\testfolder\")
set fc = fo.Files
set f = fc.FileSize
If f=("0") Then
WScript.Echo "File Found"
Else
End If
End Function