Where exactly is your problem?
used = size - free
so all you have to do is use $calc($haddrives(size) - $harddrivers(free))
Two notes:
1. There's no point in using both "3" and "k" in $bytes. "3" automatically picks the appropriate unit (B,KB,MB,GB etc) and overrides "k".
2. Looping through all letters three times (once for size, free and limit) is unecessarily slower. You could instead set variables for free, used and size in a single loop (and perhaps have $harddrives return them all in a row, when you call it with something like $harddrives(all)). If you don't want to do that, you can at least use $disk(N) (where N is a number and not a letter), so that if you have 10 drives on your system, it'll only do 10 iterations and not 24.
Last edited by qwerty; 24/03/05 06:44 PM.