StumpedTechy
MIS
How is it when I take the time variable it does not log the "real time" it just logs the time from the start of the script? I am trying to do logging and the fact the time only shows the start of the script helps me in no way when I have 5 lines and all show the exact same time.
E.G.
scripr body -
yields
-12/27/2006 @ 2:39:42 PM- 'ORL03LDTEST' Checking for C:\LDCLIENT\DATA\LDISCAN.CFG.
-12/27/2006 @ 2:39:42 PM- 'ORL03LDTEST' No LDISCAN file at C:\LDCLIENT\DATA\LDISCAN.CFG.
-12/27/2006 @ 2:39:42 PM- 'ORL03LDTEST' checking for C:\LDISCAN.CFG.
-12/27/2006 @ 2:39:42 PM- 'ORL03LDTEST' No LDISCAN file at C:\LDISCAN.CFG.
I know that this isn't happening in 1)the same milliscond and I also know that if I add an exe that takes 15 mins to run it still shows the same time. it still shows the same time.
Is there something in the script to make it so it captures real date/time information not just date/time from when the script starts?
E.G.
scripr body -
Code:
objFileOutput.WriteLine "-"&Date&" @ "&Time&"- '" & strComputer & "' Checking for C:\LDCLIENT\DATA\LDISCAN.CFG."
If objFSO.FileExists("\\" & strComputer & "\C$\LDCLIENT\DATA\LDISCAN.CFG") Then
objFSO.DeleteFile "\\" & strComputer & "\C$\LDCLIENT\DATA\LDISCAN.CFG"
objFileOutput.WriteLine "-"&Date&" @ "&Time&"- '" & strComputer & "' LDISCAN deleted from C:\LDCLIENT\DATA\LDISCAN.CFG."
Else
objFileOutput.WriteLine "-"&Date&" @ "&Time&"- '" & strComputer & "' No LDISCAN file at C:\LDCLIENT\DATA\LDISCAN.CFG."
End If
objFileOutput.WriteLine "-"&Date&" @ "&Time&"- '" & strComputer & "' checking for C:\LDISCAN.CFG."
If objFSO.FileExists("\\" & strComputer & "\C$\LDISCAN.CFG") Then
objFSO.DeleteFile "\\" & strComputer & "\C$\LDISCAN.CFG"
objFileOutput.WriteLine "-"&Date&" @ "&Time&"- '" & strComputer & "' LDISCAN deleted from C:\LDISCAN.CFG."
Else
objFileOutput.WriteLine "-"&Date&" @ "&Time&"- '" & strComputer & "' No LDISCAN file at C:\LDISCAN.CFG."
yields
-12/27/2006 @ 2:39:42 PM- 'ORL03LDTEST' Checking for C:\LDCLIENT\DATA\LDISCAN.CFG.
-12/27/2006 @ 2:39:42 PM- 'ORL03LDTEST' No LDISCAN file at C:\LDCLIENT\DATA\LDISCAN.CFG.
-12/27/2006 @ 2:39:42 PM- 'ORL03LDTEST' checking for C:\LDISCAN.CFG.
-12/27/2006 @ 2:39:42 PM- 'ORL03LDTEST' No LDISCAN file at C:\LDISCAN.CFG.
I know that this isn't happening in 1)the same milliscond and I also know that if I add an exe that takes 15 mins to run it still shows the same time. it still shows the same time.
Is there something in the script to make it so it captures real date/time information not just date/time from when the script starts?