Symbian Developer Library

SYMBIAN OS V6.1 EDITION FOR C++

[Index] [Glossary] [Previous] [Next]



Using RFormat

The RFormat class formats a device, one step at a time.

The object must first be opened on a device, and then each track is formatted using Next(). The following code fragment shows how this is done:

...
_LIT(KDriveA,"A:");
...
RFs fs;
User::LeaveIfError(fs.Connect());
...
RFormat format;
TInt tracksRemaining;
User::LeaveIfError(format.Open(fs,KDriveA,EHighDensity,tracksRemaining));
while (tracksRemaining)
    {
    User::LeaveIfError(format.Next(tracksRemaining));
    }
format.Close();