mIRC Home    About    Download    Register    News    Help

Print Thread
return file/drive size #105929 22/12/04 08:19 AM
Joined: Oct 2003
Posts: 80
R
RockHound Offline OP
Babel fish
OP Offline
Babel fish
R
Joined: Oct 2003
Posts: 80
I have not been around scripting for long time so please bear with me. Im trying to get the $disk(c:).size to return as 64GB. How would I do this with out using a calcultation?


RockHound
Re: return file/drive size #105930 22/12/04 08:27 AM
Joined: Dec 2002
Posts: 11
D
DixrouE Offline
Pikka bird
Offline
Pikka bird
D
Joined: Dec 2002
Posts: 11
$bytes($disk(c:).size).suf


DixrouE
Re: return file/drive size #105931 22/12/04 08:32 AM
Joined: Oct 2003
Posts: 80
R
RockHound Offline OP
Babel fish
OP Offline
Babel fish
R
Joined: Oct 2003
Posts: 80
Ty was having hard time trying to remember and find it in help file


RockHound
Re: return file/drive size #105932 22/12/04 07:43 PM
Joined: Aug 2004
Posts: 237
L
LethPhaos Offline
Fjord artisan
Offline
Fjord artisan
L
Joined: Aug 2004
Posts: 237
and how to return the used space in gb?

Re: return file/drive size #105933 22/12/04 07:54 PM
Joined: Feb 2004
Posts: 2,019
FiberOPtics Offline
Hoopy frood
Offline
Hoopy frood
Joined: Feb 2004
Posts: 2,019
Usage: $hdused(drive)

Examples: //echo -a Used: $hdused(c) * $hdused(d)

alias hdused return $bytes($calc($disk($1).size - $disk($1).free),g).suf

Didn't add any error checking, I leave that for you grin

Greets


Gone.
Re: return file/drive size #105934 22/12/04 07:57 PM
Joined: Dec 2002
Posts: 3,547
S
SladeKraven Offline
Hoopy frood
Offline
Hoopy frood
S
Joined: Dec 2002
Posts: 3,547
Code:
$calc($bytes($disk(c:).size) - $bytes($disk(c:).free)) $+ GB

maybe?