Questo è il codice che uso:
CMessageData *message=CMessageData::NewLC();
_LIT(KSubject, "mio subject");
message->SetSubjectL(&KSubject);
message->AppendToAddressL(_L("indirizzo@mioindirizzo.com"));
//Creation Body Email
CRichText* iRichText; // rich text document
CParaFormatLayer* iParaFormatLayer;// global paragraph format layer
CCharFormatLayer* iCharFormatLayer;// global character format layer
iParaFormatLayer=CParaFormatLayer::NewL(); // required para format
iCharFormatLayer=CCharFormatLayer::NewL(); // required char format
iRichText=CRichText::NewL(iParaFormatLayer, iCharFormatLayer);
TInt pos=0; // will be insertion position
// insert some rich text
iRichText->InsertL(pos,_L("Add your commment\n\nApplication Name: my app 1.0"));
//End creation body Email
message->SetBodyTextL(iRichText);
//Start message editor through SendUI
CSendUi *iSendUi=CSendUi::NewLC();
iSendUi->CreateAndSendMessageL(KSenduiMtmSmtpUid, message, KNullUid );
qDebug()<<"After CreateAndSendMessageL";
Il problema è che funziona tutto però come dico di cancellare il messaggio, quindi non lo invio, l'applicazione si pianta. Qualche idea?
In più sapete come far diventare questo processo asincrono?
Grazie.
Messaggio modificato da qwertyuiopearendil il 03 maggio 2010 - 16:23

Aiuto












Pubblicità