DelphiFAQ Home Search:

Send email from Delphi

 

comments25 comments. Current rating: 5 stars (9 votes). Leave comments and/ or rate it.

It can be so easy to have your application pop up an email window.. assuming that a mail reader is installed (see below):

(Thanks to Kevin for improving the code with the body= parameter.)

uses
  ShellAPI;
	
begin
  ShellExecute(0,'open','mailto: peter@preview.org?subject=my subject&body=my message text',
               NIL, NIL, SW_SHOWNORMAL);
end

Content-type: text/html

Comments:

You are on page 1 of 2, other pages: [1] 2
2005-11-30, 11:58:53
anonymous from United States  
rating
2006-03-31, 13:29:25
anonymous from Morocco  
j'ai l'honneur pour ecrire ce petite demande pour me postuler un poste dans votre etablissment .
jbilou ahmed
2006-05-28, 23:09:49
anonymous from India  
How i can send mails yahoo mail id etc through delphi program
2006-06-22, 03:47:44
Gilby from Hungary  
rating
That is what I looked for!
2006-09-26, 06:57:20
Share√® from South Africa  
rating
Thanks, short and sweet and very helpful!
2006-11-06, 05:38:41
RTS from Poland  
rating
That is what I looked for!
2007-02-27, 17:44:49
Shendrik from Israel  
rating
Thank you!!!
2007-05-08, 04:36:07
anonymous from India  
Exellent and gud help
thank you......
2008-01-23, 00:27:54
anonymous from Azerbaijan  
Good, But
I dont need OutLook sending. How can Isenda wiht other way?
You are on page 1 of 2, other pages: [1] 2

 

 

NEW: Optional: Register   Login
Email address (not necessary):

Rate as
Hide my email when showing my comment.
Please notify me once a day about new comments on this topic.
Please provide a valid email address if you select this option, or post under a registered account.
 

Show city and country
Show country only
Hide my location
You can mark text as 'quoted' by putting [quote] .. [/quote] around it.
Please type in the code:

Please do not post inappropriate pictures. Inappropriate pictures include pictures of minors and nudity.
The owner of this web site reserves the right to delete such material.

photo Add a picture: