This probably won't help you a lot, because I guess you're looking for
some programming hints and not for a piece of software. Anyway, a
programm that just displays the amount of diskspace free/used already
exists and its called b.exe (or is it b.com ?). I can give you some
detailed info, if you like.