Very Nice!!
Is it possible to get the output into a html page?
it would be great if it could work with the code below.
thanks!
filedelete %A_ScriptDir%\printout.htm
htmlhead =
(
<html><head><title>printout</title>
<style type="text/css" media=screen,print>
<!--
body,td,H1 {font-family: "arial";font-size: 11pt}
// -->
</style></head>
<body><h1><br>Drives<br></h1>
<table align=left border=0 width=50`%>
)
fileappend, %htmlhead%, %A_ScriptDir%\printout.htm
objWMIService := ComObjGet("winmgmts:\\.\root\cimv2")
colItems := objWMIService.ExecQuery("SELECT * FROM Win32_LogicalDisk")._NewEnum
while colItems[objItem]
{
a := objItem.Caption, b := objItem.FileSystem, c := Round((objItem.Size / (1024 ** 3)), 2)
d := Round((objItem.FreeSpace / (1024 ** 3)), 2), e:= Round((100 * (objItem.FreeSpace / objItem.Size)), 2)
htmlbody =
(
<tr><td width=100`%>Drive: %a% </td></tr>
<tr><td>File System: %b%</td></tr>
<tr><td>Drive Size: %c% GB</td></tr>
<tr><td>Free Space: %d% GB</td></tr>
<tr><td>Free Space: %e% `%</td></tr><tr><td>-----------------------------</td></tr>
)
fileappend, %htmlbody%, %A_ScriptDir%\printout.htm
}
fileappend, </font></table></body></html>, %A_ScriptDir%\printout.htm
Runwait, %A_ScriptDir%\printout.htm