You can find info by searching around the delphi.about.com site, but here's 
something to get you started:

procedure TForm1.btnEmailClick(Sender: TObject);
var
  em_subject, em_body, em_mail: string; //em_mail is the whole mail message; 
em_subject & em_body are
                                                             //the subject 
line and message body
begin
  em_subject := 'Message Subject Line Here';
  em_body := 'Text of e-mail message goes here';
  em_mail := 'mailto:[EMAIL PROTECTED]' + em_subject + '&body=' + 
em_body;
  //convert Delphi's carriage returns to a version email programs like 
Outlook Express understand:
  em_mail:=StringReplace(em_mail,#13#10,'%0D%0A',[rfReplaceAll]);
  ShellExecute(Handle, 'open', PChar(em_mail), nil, nil, SW_SHOWNORMAL);
end;

Hope this helps. -- Al C.

----- Original Message ----- 
From: "Wayne Roser" <[EMAIL PROTECTED]>
To: <[email protected]>
Sent: Monday, October 31, 2005 11:49 AM
Subject: Want to access default mail client


> I've never done any mail stuff before and want to get started; maybe read 
> an article ...
>
> I need to throw up an email using the default mail client after filling in 
> a couple of fields so
> that the user can enter a message or modify the subject line or whatever.
>
> TIA
> Wayne Roser
>
> _______________________________________________
> Delphi mailing list -> [email protected]
> http://www.elists.org/mailman/listinfo/delphi
> 
_______________________________________________
Delphi mailing list -> [email protected]
http://www.elists.org/mailman/listinfo/delphi

Reply via email to