Sorry, I forgot to make a change.  You will need to change "COMPUTER_NAME"<br>~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~<br> >>> from win32com.client import GetObject<br>>>> wmiObj = GetObject("winmgmts:\\\\COMPUTER_NAME\\root\\cimv2")
<br><div id="mb_1">>>> diskinfo = wmiObj.ExecQuery("Select * from Win32_LogicalDisk")
<br>>>> for disk in diskinfo:<br>...    print disk.Name, disk.FreeSpace</div><br><br><div><span class="gmail_quote">On 28 Feb 2007 12:26:31 -0800, <b class="gmail_sendername"><a href="mailto:kevinliu23@gmail.com">
kevinliu23@gmail.com</a></b> <<a href="mailto:kevinliu23@gmail.com">kevinliu23@gmail.com</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
HI,<br><br>I am new to Python and wanted to know how to check for the remaining<br>disk space on my Windows machine using Python? I was thinking of using<br>the command line "dir" and trying to extract the output from there.
<br>But I'm not sure how to extract command line strings using Python<br>either.<br><br>Anyway help would be appreciated. :)<br><br>--<br><a href="http://mail.python.org/mailman/listinfo/python-list">http://mail.python.org/mailman/listinfo/python-list
</a><br></blockquote></div><br>