Sunday, July 29, 2007

How to get the free space of every drive

Following Code can get you the free space in a drive.

RFs iFs;
iFs.Connect();
TInt err = iFs.Volume( volinfo, EDriveC );
TInt64 space = volinfo.iFree;
iFs.Close();
"iFree" is the amount of free space on the disk in bytes.

Note: Volume() will return KErrNotReady if the drive contains no media.

No comments:

stats counter