My script below is part of a script that exports files into one compressed file. I want my script below to check the file size and when it has not increased for 3 consecutive checks to report that the build is complete. I have managed to get it to report the file size, but I need it to keep checking the file size every 10 seconds and report complete if it has not changed in the last 3 checks.
Any Ideas how I can do this.
Set objExplorer = CreateObject("InternetExplorer.Application")
Set fso = CreateObject("Scripting.FileSystemObject")
objExplorer.Navigate "about:blank"
objExplorer.ToolBar = 0
objExplorer.StatusBar = 0
objExplorer.Width = 400
objExplorer.Height = 200
objExplorer.Left = 0
objExplorer.Top = 0
objExplorer.Visible=1
do While (objExplorer.Busy)
Loop
Set objDocument = objExplorer.Document
objDocument.Open
objDocument.WriteLn "<html><head><title>LREP Data Replication</title></head>"
objDocument.WriteLn "<body bgcolor='white'>"
objDocument.WriteLn "Replicating Data to USB Device. Please Wait....<p>"
Set objFSO = CreateObject("Scripting.FileSystemObject")
Set objFile = objFSO.GetFile("d:\scripts\random.fil")
'wscript.echo("File Size so far = " & (objFile.Size) & "bytes")
objDocument.WriteLn("File Size so far =" & (objFile.Size) & " bytes")
Any Ideas how I can do this.
Set objExplorer = CreateObject("InternetExplorer.Application")
Set fso = CreateObject("Scripting.FileSystemObject")
objExplorer.Navigate "about:blank"
objExplorer.ToolBar = 0
objExplorer.StatusBar = 0
objExplorer.Width = 400
objExplorer.Height = 200
objExplorer.Left = 0
objExplorer.Top = 0
objExplorer.Visible=1
do While (objExplorer.Busy)
Loop
Set objDocument = objExplorer.Document
objDocument.Open
objDocument.WriteLn "<html><head><title>LREP Data Replication</title></head>"
objDocument.WriteLn "<body bgcolor='white'>"
objDocument.WriteLn "Replicating Data to USB Device. Please Wait....<p>"
Set objFSO = CreateObject("Scripting.FileSystemObject")
Set objFile = objFSO.GetFile("d:\scripts\random.fil")
'wscript.echo("File Size so far = " & (objFile.Size) & "bytes")
objDocument.WriteLn("File Size so far =" & (objFile.Size) & " bytes")