Home All Groups Group Topic Archive Search About

Sending E-Mails "MailTo" Style

Author
28 Aug 2006 6:07 PM
howardw@nospam.nospam
I use classes in the  System.Net.Mail namespace to send e-mails
programatically.

However what I want to do is the following: When the user clicks a button to
send mail, the effect is like what happens when you click a MailTo link in a
Web Browser. That is, (assuming Outlook is the user's mail client), an
Outlook mail message window is created and pops up on the user's screen.
Various elements of the message have been pre-filled programatically. The
user can add to or change any of these, and then send the message.

How would I do this?

Author
28 Aug 2006 6:12 PM
Siva M
Try this:

System.Diagnostics.Process.Start("mailto:em***@example.com?Subject=Test
body&Cc***@example.com&Body=Test body");

This prefilss To, Cc, Subject & Body.

HTH.

"howardw@nospam.nospam" <howardwnospamnospam@discussions.microsoft.com>
wrote in message news:431AE03F-6E31-4325-8A93-5C2B36905724@microsoft.com...
I use classes in the  System.Net.Mail namespace to send e-mails
programatically.

However what I want to do is the following: When the user clicks a button to
send mail, the effect is like what happens when you click a MailTo link in a
Web Browser. That is, (assuming Outlook is the user's mail client), an
Outlook mail message window is created and pops up on the user's screen.
Various elements of the message have been pre-filled programatically. The
user can add to or change any of these, and then send the message.

How would I do this?
Author
28 Aug 2006 7:05 PM
howardw@nospam.nospam
Thanks!!

Show quote
"Siva M" wrote:

> Try this:
>
> System.Diagnostics.Process.Start("mailto:em***@example.com?Subject=Test
> body&Cc***@example.com&Body=Test body");
>
> This prefilss To, Cc, Subject & Body.
>
> HTH.
>
> "howardw@nospam.nospam" <howardwnospamnospam@discussions.microsoft.com>
> wrote in message news:431AE03F-6E31-4325-8A93-5C2B36905724@microsoft.com...
> I use classes in the  System.Net.Mail namespace to send e-mails
> programatically.
>
> However what I want to do is the following: When the user clicks a button to
> send mail, the effect is like what happens when you click a MailTo link in a
> Web Browser. That is, (assuming Outlook is the user's mail client), an
> Outlook mail message window is created and pops up on the user's screen.
> Various elements of the message have been pre-filled programatically. The
> user can add to or change any of these, and then send the message.
>
> How would I do this?
>
>
>

AddThis Social Bookmark Button