Solved

How to open a new mail in default email program (outlook) with subject and body message

Posted on 2004-05-02
4
407 Views
Last Modified: 2010-04-15
I have a c# program that have a "Compose Email" button. When you press this button, the program retrieves some data from the database and creates a "to" string, "subject" string and "body" string. I have done this part. But then I want my program to execute the default mail program (normally outlook/outlook express) and start up a new mail where the "to", "subject", and "body" fields are filled out with the three strings I have created. I don't want the mail to be sent automatically, the user still has to press the send button. Can anybody please help me with this??
0
Comment
Question by:astensland
  • 2
4 Comments
 
LVL 69

Accepted Solution

by:
Éric Moreau earned 50 total points
ID: 10973525
Use this:
System.Diagnostics.Process.Start("mailto:hi@hello.com?subject=testletter&body=content");
0
 

Author Comment

by:astensland
ID: 10975047
Brilliant emoreau!!! Thanx alot...
0
 

Expert Comment

by:kevlarkevin
ID: 11201380
I get Access Is Denied when Using this - Can you help?
0
 
LVL 69

Expert Comment

by:Éric Moreau
ID: 11201752
kevlarkevin, post your own question!
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Bit flags and bit flag manipulation is perhaps one of the most underrated strategies in programming, likely because most programmers developing in high-level languages rely too much on the high-level features, and forget about the low-level ones. Th…
This article introduced a TextBox that supports transparent background.   Introduction TextBox is the most widely used control component in GUI design. Most GUI controls do not support transparent background and more or less do not have the…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.
This video gives you a great overview about bandwidth monitoring with SNMP and WMI with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're looking for how to monitor bandwidth using netflow or packet s…

760 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

Need Help in Real-Time?

Connect with top rated Experts

21 Experts available now in Live!

Get 1:1 Help Now