PDA

View Full Version : How to send email and attachement via default email client



richardander
30th November 2009, 20:47
Hello,

In my QT application, I would like to send an email and an attachement via the default email client program so that I do not need to handle mail server, port ....

My problems are:

- How to finding out the default email client in current OS

- what arguments to pass to it to in order to attach a file to it

- how to start the program. it is likely to use QProcess::startDetached.

Is there anyone have the experience to do it?

thank you in advance!

MarkoSan
30th November 2009, 22:06
Hmmm, you could maybe subclass QSettings and then separate the code according to OS (with #ifdefs) and for Windows, you could search in registry, for Linux in ini files, ... It is just a proposal.

wysota
30th November 2009, 22:13
http://www.ianr.unl.edu/internet/mailto.html

aamer4yu
1st December 2009, 05:40
This might help too..
Introducing QMF an advanced mobile messaging framework (http://labs.trolltech.com/blogs/2009/09/21/introducing-qmf-an-advanced-mobile-messaging-framework/)