?
Solved

How to launch default email client?

Posted on 2000-04-03
9
Medium Priority
?
140 Views
Last Modified: 2010-04-04
I am writing a program, it generate
a report at c:\temp\myreport.htm,
how to launch user's default email
client and automatically attach it when
user press a button?

Thanks

Shekou
0
Comment
Question by:shekou
  • 4
  • 3
  • 2
9 Comments
 
LVL 13

Accepted Solution

by:
Epsylon earned 300 total points
ID: 2679417
Try this app from Simonet AKA Alex (source included):

http://www.bhnet.com.br/~simonet/archive/mapimail.zip
0
 
LVL 15

Expert Comment

by:simonet
ID: 2679625
>Simonet AKA Alex

I guess it's the other way around, Epsylon!
0
 
LVL 13

Expert Comment

by:Epsylon
ID: 2680598
I think both ways are right...
0
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

 

Author Comment

by:shekou
ID: 2682781
Is there any simple way use shellexecute
to implement that?

Rgds

Shekou
0
 
LVL 13

Expert Comment

by:Epsylon
ID: 2682894
Not when you want to attach files.
0
 

Author Comment

by:shekou
ID: 2683087
Find  a command like this:
ShellExecute( 0, 'Open', PChar('mailto:somebody@somewhere.com?Subject=Hey!&body=Test ), nil, nil, SW_SHOWNORMAL )
It seems could use ?Subject and &body automatically fill Subject and body field, which parameter used for attachement?

Rgds

Shekou
0
 
LVL 13

Expert Comment

by:Epsylon
ID: 2683830
Like I said, you can't use attachments this way...
0
 
LVL 15

Expert Comment

by:simonet
ID: 2685859
Epsylon is right.

By using ShellExecute you cannot attach files to the e-mail.  Only by handling MapiSendMail directly you can attach files.

shekou, please read the question again.

Alex
0
 

Author Comment

by:shekou
ID: 2686407
OK, thanks, I tried MAPISendmail, it
works.

Rgds

Shekou
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Creating an auto free TStringList The TStringList is a basic and frequently used object in Delphi. On many occasions, you may want to create a temporary list, process some items in the list and be done with the list. In such cases, you have to…
Introduction Raise your hands if you were as upset with FireMonkey as I was when I discovered that there was no TListview.  I use TListView in almost all of my applications I've written, and I was not going to compromise by resorting to TStringGrid…
This video shows how to quickly and easily deploy an email signature for all users in Office 365 and prevent it from being added to replies and forwards. (the resulting signature is applied on the server level in Exchange Online) The email signat…
When cloud platforms entered the scene, users and companies jumped on board to take advantage of the many benefits, like the ability to work and connect with company information from various locations. What many didn't foresee was the increased risk…
Suggested Courses
Course of the Month13 days, 22 hours left to enroll

807 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question