Link to home
Start Free TrialLog in
Avatar of mchristo63
mchristo63

asked on

Status bar

I have the following script that reports on a specific file version.  I would like to add a status bar that shows the progress as it adds the output to a txt file.  How might I go about doing that?

WScript.Echo "Server name" & vbTab & "File Version"

Const ForReading = 1
Const ForWriting = 2

Set objDictionary = CreateObject("Scripting.Dictionary")
Set objFSO = CreateObject("Scripting.FileSystemObject")
Set objTextFile = objFSO.OpenTextFile("C:\servers.txt", ForReading)
Set objReportFile = objFSO.OpenTextFile("C:\report.txt", ForWriting)

i = 0
Do Until objTextFile.AtEndOfStream
   strNextLine = objTextFile.Readline
   objDictionary.Add i, strNextLine
   i = i + 1
Loop
For Each objItem in objDictionary
   Set objFSO = CreateObject("Scripting.FileSystemObject")
   objReportFile.WriteLine objDictionary.Item(objItem) & vbTab & objFSO.GetFileVersion _
("\\"& objDictionary.Item(objItem) & "\C$\Program Files\application\file.exe")                  

Next

Thanks
ASKER CERTIFIED SOLUTION
Avatar of cookre
cookre
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
what about Progress bar if u use progress bar i will help u
Avatar of mchristo63
mchristo63

ASKER

what?
How can i insert that script into my script?