|
|
User login
Feeds |
How to open Draft folder
|
|||||
| Mon, 2005-08-15 14:57 | |
|
I want to create applicatoin opening the draft folder and display it on the screen. Any one knows how to do using clientMtm UI? from former posts: i can get the buffer. But how can i display? Cheers! CBaseMtm*ptriMtmRegistry = CClientMtmRegistry::NewL(*iSession); CSmsClientMtm* ptrSmsMtm = static_cast<CSmsClientMtm *> (iMtmRegistry->NewMtmL(KUidMsgTypeSMS)); ptrSmsMtm ->SwitchCurrentEntryL(msvEntry.Id()); ptrSmsMtm ->LoadMessageL(); // load the message CRichText& body = ptrSmsMtm ->Body(); HBufC* msgBuffer = HBufC::NewL(body.DocumentLength() + 1) ; CleanupStack::PushL(msgBuffer) ; TPtr msg = msgBuffer->Des(); body.Extract(msg, 0) ; TInt msgLength = msg.Length() ; CleanupStack::PopAndDestroy(); |
|
Forum posts: 32
Forum posts: 192
Forum posts: 32
or using Mtm ui.
Still thinking how to do!
Forum posts: 192
theArray->AppendL(entry.iDetails);
Forum posts: 32
Try to coding. Still can not get.
But it seems i know how to get KUid type message (e.g. KUidMsgTypePOP3 ) in the draft folder!
Still thinking!
Forum posts: 32
{
TMsvId serviceId;
TMsvEntry indexEntry;
User::LeaveIfError(iMsvSession->GetEntry( KMsvDraftEntryId,serviceId,indexEntry));
if ( !iClientReg )
{
iClientReg = CClientMtmRegistry::NewL( *iMsvSession );
}
// create a client mtm
CClientMtmRegistry* clientReg = CClientMtmRegistry::NewL( *iMsvSession );
CleanupStack::PushL(clientReg);
CBaseMtm* newMtm = clientReg->NewMtmL(indexEntry.iMtm);
CleanupStack::PushL(newMtm);
// get the entry associated with the given servive ID
CMsvEntry* entry = iMsvSession->GetEntryL(serviceId);
CleanupStack::PushL(entry);
newMtm->SetCurrentEntryL(entry);
CleanupStack::Pop(2); //newMtm, entry
return ETrue;
}
But i got sysmtem error, what's wrong with my code?
Forum posts: 192
Hope, it'll help:
http://forum.newlc.com/index.php/topic,9482.0.html