I know how to get free space by one dll, but how can I get total space? I haven't found any program/code about this.
And how can I create Win 9x like piechart without any dlls and ocxs and other?
I have VB4.
Vesa Piittinen
Printable View
I know how to get free space by one dll, but how can I get total space? I haven't found any program/code about this.
And how can I create Win 9x like piechart without any dlls and ocxs and other?
I have VB4.
Vesa Piittinen
Have a look at:
http://www.vb-world.net/demos/freespace/
In the frmMain file, there is a function that display the amount of free space on the drive. It works out the number of free bytes with this line:
FreeBytes = NumberOFreeClusters * SectorsPerCluster * BytesPerSector
You could also add this line because the API call returns the total number of clusters on the hard disk:
TotalBytes = TotalNumberOfClusters * SectorsPerCluster * BytesPerSector
To draw pie charts, you could start by having a look at the Circle method. It allows you to draw bits of circles as well as whole circles.
------------------
John Percival
Editor, VB-World.net
[email protected]