473,466 Members | 1,376 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Email format in c# [NOT sending/making it]

110 New Member
Hi,

Please bear with me if this sounds like a non-intuitive question. Anyone have any insights as to how System.Net.MailMessage class is implemented?

Does it construct a simple C/MIME string and append the properties to it? Does it do the following? The following is just a guess so I would really appreciate it if someone were to point me to something about email format(s)...

Expand|Select|Wrap|Line Numbers
  1. string message = "To: " + toVar + "\n" +
  2.  "From: " + fromVar + "\n"
  3.  "CC: " + ccVar + "\n"
  4.  
  5.  
I want to construct a few messages then poll my server to collect performance stats. To be able to correctly measure the performance I need to know the simple email format...its just c/mime (and therefore just text) isnt it? Then i can add headers to it, right?

thanks!
Aug 26 '09 #1
1 1703
cloud255
427 Recognized Expert Contributor
Well according to this article the code you supplied will generate a plain text email...

You can add headers to the mail with the following code;

Expand|Select|Wrap|Line Numbers
  1. MyMailMessage.Headers.Add("key", "value");
Hope this helps
Aug 26 '09 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: Paul Lamonby | last post by:
Hi, I am sending a file from the server as an email attachment. The file is being attached no problem and sending the email, but I get an error when I try to open it saying it is corrupt....
1
by: Jackdan | last post by:
Hi everyone, I am making a little web interface so that the secretaries at my dad's office stop getting lost in thunderbird...*laughs*. Anyways, I have no problem displaying the emails or sending...
4
by: Nathan Sokalski | last post by:
I have a form which will be processed by being sent to an ASP page. I would like the ASP page to take the data from the Request.QueryString (which I know how to do) and format it so I can have it...
6
by: magister | last post by:
Hi I am sending emails from my website. The from field usually is an email address, but alot of email readers also seem to be able to pickup a "from real name". I read somewhere that I can set...
4
by: Francois Keyeux | last post by:
hello everyone: i have a web site built using vbasic active server scripting running on iis (it works on either iis 50 and 60, but is designed for iis 50) i know how to create a plain text...
1
by: Emmanuel | last post by:
hi, i want to make a tool which automates email replies. How can i include the original message body in my reply using the same format as a normal email client would do, in both html and text...
7
by: Susan Bricker | last post by:
I would like to generate a report (I have the report working already) using MS/ACCESS 2000 and then have the ability to send the report as an email attachment to my colleagues. I have looked...
2
by: Rich | last post by:
Hello, I need to send an automated email message from my application (vb2005) - using system.net.mail. What I need to do to the message is to format the text, like underlining, bolding,...
14
by: active | last post by:
Because of a strong recommendation I saw in this NG all my events are of the form: Public Event HeightChanged(ByVal sender As Object, ByVal e As HeightChangeEventArgs) where: Public...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.