Thanks first.
Here is the code to move a new received message in Inbox
to a new folder under "My folder" folder,
but it did not work as I expected.
//======================================code start=============================
void CMySMSHandler::MoveToFolderL( TMsvId aMessageId, TMsvId aFolder )
{
iSmsMtm->SwitchCurrentEntryL( aMessageId );
TMsvSelectionOrdering selection;
selection.SetShowInvisibleEntries(ETrue);
CMsvEntry* parentEntry = CMsvEntry::NewL( iSmsMtm->Session(),
iSmsMtm->Entry().Entry().Parent(), selection );
CleanupStack::PushL(parentEntry);
// Move the message
parentEntry->MoveL( aMessageId, aFolder );
CleanupStack::PopAndDestroy(parentEntry); // parentEntry
}
//======================================code end=============================
When it comes to execute the following line,
parentEntry->MoveL( aMessageId, aFolder );
it returns immediately to
void CMySMSHandler::HandleSessionEventL(TMsvSessionEvent aEvent,
TAny* aArg1,
TAny* aArg2,
TAny* aArg3);
with an error code(just some integer,I don't remember it).
What is wrong with my code?
Or what is wrong?
Would any guy help?
Thank you a lot.
I will be back next Monday.




