×
Namespaces

Variants
Actions
(Difference between revisions)

Send a new email in Qt

From Nokia Developer Wiki
Jump to: navigation, search
hamishwillee (Talk | contribs)
m (Text replace - "<code cpp>" to "<code cpp-qt>")
hamishwillee (Talk | contribs)
m (Hamishwillee -)
 
Line 1: Line 1:
[[Category:Messaging]][[Category:Qt Mobility]]
+
[[Category:MeeGo Harmattan]][[Category:Symbian]][[Category:E-Mail]][[Category:Qt]]
 
{{Abstract|visible=true|This code example shows how to send an email using the Qt Mobility [http://doc.qt.nokia.com/qtmobility-1.1/messaging.html messaging] API}}.
 
{{Abstract|visible=true|This code example shows how to send an email using the Qt Mobility [http://doc.qt.nokia.com/qtmobility-1.1/messaging.html messaging] API}}.
  
Line 45: Line 45:
 
* [[Send MMS using Qt Mobility]]
 
* [[Send MMS using Qt Mobility]]
 
* [[Read and Send messages in Qt for Symbian]]
 
* [[Read and Send messages in Qt for Symbian]]
* [[Delete messages using Qt Mobility API in Qt for Symbian]][[Category:MeeGo Harmattan]] [[Category:Symbian]]
+
* [[Delete messages using Qt Mobility API in Qt for Symbian]]

Latest revision as of 09:42, 14 June 2013

This code example shows how to send an email using the Qt Mobility messaging API.

Article Metadata
Compatibility
Platform(s):
Symbian
Article
Created: talk2mks (11 Apr 2011)
Last edited: hamishwillee (14 Jun 2013)
//Create message service objects
QMessageServiceAction* msgAction = new QMessageServiceAction ( this);
 
// Create a new email
QMessage msg;
msg.setType(QMessage::Email);
// Add required parameters
msg.setTo (QMessageAddress("qt@forum.nokia.com",QMessageAddress::Email));
msg.setSubject("QT email example");
 
//Set message body
msg.setBody("This is test message!");
 
// Add Attachments
QStringList attachments;
attachments.append("abc.jpg");
msg.appendAttachments(paths);
 
//Send email message
msgAction->send(msg);

[edit] Related topics

This page was last modified on 14 June 2013, at 09:42.
158 page views in the last 30 days.
×