HELP with .VBS file
I am writing a .vbs file and the highlighted part of my function code below is not working. The error that I am getting is "PATH NOT FOUND". What am I doing wrong? Here is the code (THANKS):
Function LogErrorToFile ()
Dim objFS
Dim objFile
LogErrorToFile = False
Set objFS = WScript.CreateObject("Scripting.FileSystemObject")
If strYear + strMonth + strDay <> strDate Then
Set objFile = objFS.CreateTextFile (strFile, False)
Else
Set objFile = objFS.OpenTextFile (strFile, 8, True) End If
|