Symbian
Symbian OS Library

SYMBIAN OS V9.3

[Index] [Spacer] [Previous] [Next]



How to delete files and directories

Use RmDir() to delete an empty directory. Use Delete() to delete a file.

// Deletes KTopDir, deleting all files and sub-directories first
User::LeaveIfError(fsSession.Delete(KFile2));
User::LeaveIfError(fsSession.RmDir(KDir1));
User::LeaveIfError(fsSession.RmDir(KDir2));
User::LeaveIfError(fsSession.Delete(KFile1));
User::LeaveIfError(fsSession.RmDir(KTopDir)); ... 


Notes