Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much
 
PerlMonks  

Re^2: hard drive space

by bmann (Priest)
on Oct 03, 2007 at 00:57 UTC ( [id://642273]=note: print w/replies, xml ) Need Help??


in reply to Re: hard drive space
in thread hard drive space

Here's another Win32 specific method using windows scripting FileSystemObject:

use warnings; use strict; use Win32::OLE; my $fso = Win32::OLE->CreateObject('Scripting.FileSystemObject'); my $drive = $fso->GetDrive('C:'); my $free = $drive->{FreeSpace}; my $size = $drive->{TotalSize}; printf "disk size = %d MB\n", $size/(1024*1024); printf "disk free = %d MB\n", $free/(1024*1024);

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://642273]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others browsing the Monastery: (5)
As of 2024-04-25 10:40 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found