Script up to line 57 -
Code:
Shell "%COMSPEC% /e:1024 /c c:\windows\netview.exe /NTS /BDC /PDC >c:\admin\kix2010_451\servers.txt"
If @error<>0
? "Netview is not found !"
?
? " You have to download netview at (http://www.optimumx.com/download/#NetView)"
? " and place it in this script directory."
Quit
EndIf
$line=""
If Open(3, "c:\admin\kix2010_451\servers.txt") = 0
$x = ReadLine(3)
While @ERROR = 0
If $x<>""
$pos=InStr($x," ")
$xf=Left($x,$pos-1)
If InStr($x,"\\")<>0
$xf=Right($xf,Len($xf)-2)
$line=$line+"~~"+$xf
EndIf
EndIf
$x = ReadLine(3)
Loop
$=Close (3)
EndIf
$servarray=Split($line,"~~")
debhtml()
For Each $strComputer in $servarray
If $strComputer<>""
? "In progress for "+$strComputer+" ..."
$objWMIService = GetObject("winmgmts:\\"+$strComputer+"\root\cimv2")
If @ERROR=0
breakl()
$DiskSet = $objWMIService.ExecQuery("select * from Win32_LogicalDisk where DriveType=3")
$co=0
For Each $Disk In $DiskSet
$co=$co+1
$dname=$Disk.Name
$percentfree=Round(DISKSPACE($strComputer,$dname,5))
$percentused=100-$percentfree
$rest=$percentfree-5
html($strComputer,$dname,$percentused,$rest,$space)