Removing
attachments from messages
The messaging framework allows you to remove attachments from messages.
Attachments to
a message may be removed.
- Get the details
of the message to which you want to add an attachment using CMsvEntry::EditStoreL().
This function returns CMsvStore in writable mode.
- Get an MMsvAttachmentManager attachment
manager for the message entry, using CMsvStore::AttachmentManagerL().
Remove an attachment using the MMsvAttachmentManager::RemoveAttachmentL() function.
void CFoo::RemoveAttachL(TInt aNum)
{
...
TRequestStatus status;
// Remove attachment with index aNum
attManager.RemoveAttachmentL(aNum, status);
// Wait for request to complete
User::WaitForRequest(status);
...
}
Copyright ©2010 Nokia Corporation and/or its subsidiary(-ies).
All rights
reserved. Unless otherwise stated, these materials are provided under the terms of the Eclipse Public License
v1.0.