Hi,
I use MailMessage class for create email.
I specify such settings:
mmEmail = New MailMessage
mmEmail.To = ".."
mmEmail.Body = "..."
mmEmail.Subject = "..."
mmEmail.BodyFormat = MailFormat.Text
SmtpMail.SmtpServer = "..."
SmtpMail.Send(mmEmail)
when I get email send by such code, I can not explain the source of "From"
..
How can I check "FROM" property and change it.
This question not for "spam" programming.
Thanks 6 2181
Hi,
The mail message class a from property. http://msdn.microsoft.com/library/de...sfromtopic.asp
Ken
------------------------------
"Jul" <ju********@sympatico.ca> wrote in message
news:zZ*********************@news20.bellglobal.com ...
Hi,
I use MailMessage class for create email.
I specify such settings:
mmEmail = New MailMessage
mmEmail.To = ".."
mmEmail.Body = "..."
mmEmail.Subject = "..."
mmEmail.BodyFormat = MailFormat.Text
SmtpMail.SmtpServer = "..."
SmtpMail.Send(mmEmail)
when I get email send by such code, I can not explain the source of "From"
..
How can I check "FROM" property and change it.
This question not for "spam" programming.
Thanks
Jul,
In addition to Ken's link on the MailMessage.From property itself.
The System.Web.Mail FAQ ( http://www.systemwebmail.net/) has some addition
info on the From property (as well as MailMessage itself): http://www.systemwebmail.net/faq/2.4.aspx
Hope this helps
Jay
"Jul" <ju********@sympatico.ca> wrote in message
news:zZ*********************@news20.bellglobal.com ... Hi,
I use MailMessage class for create email.
I specify such settings: mmEmail = New MailMessage mmEmail.To = ".." mmEmail.Body = "..." mmEmail.Subject = "..." mmEmail.BodyFormat = MailFormat.Text SmtpMail.SmtpServer = "..." SmtpMail.Send(mmEmail)
when I get email send by such code, I can not explain the source of "From" . How can I check "FROM" property and change it.
This question not for "spam" programming.
Thanks
Hi ,
Thanks for you answers, but I still have a question.
I did not set up "From" property, but it contain value when I get mail.
How that property was set up?
"Jay B. Harlow [MVP - Outlook]" <Ja************@msn.com> wrote in message
news:#m**************@TK2MSFTNGP15.phx.gbl... Jul, In addition to Ken's link on the MailMessage.From property itself.
The System.Web.Mail FAQ (http://www.systemwebmail.net/) has some addition info on the From property (as well as MailMessage itself):
http://www.systemwebmail.net/faq/2.4.aspx
Hope this helps Jay
"Jul" <ju********@sympatico.ca> wrote in message news:zZ*********************@news20.bellglobal.com ... Hi,
I use MailMessage class for create email.
I specify such settings: mmEmail = New MailMessage mmEmail.To = ".." mmEmail.Body = "..." mmEmail.Subject = "..." mmEmail.BodyFormat = MailFormat.Text SmtpMail.SmtpServer = "..." SmtpMail.Send(mmEmail)
when I get email send by such code, I can not explain the source of
"From" . How can I check "FROM" property and change it.
This question not for "spam" programming.
Thanks
Jul,
I'm really not sure what you are asking, what is it set to on the emails you
received?
If its not what you expect, then I would suggest using MailMessage.From to
change it.
Are you using .NET 1.0, 1.1 or the 2.0 beta?
Which OS are you running under?
Are you running under Windows Forms, a Windows Server, or ASP.NET?
FWIW: On .NET 1.1 (VS.NET 2003) on Windows XP SP2 in a Windows Forms, using
Cox for the SmptServer, the From field is required, you receive an exception
if you leave From at the default of Nothing.
Hope this helps
Jay
"Jul" <ju********@sympatico.ca> wrote in message
news:0d****************@news20.bellglobal.com... Hi ,
Thanks for you answers, but I still have a question. I did not set up "From" property, but it contain value when I get mail. How that property was set up?
"Jay B. Harlow [MVP - Outlook]" <Ja************@msn.com> wrote in message news:#m**************@TK2MSFTNGP15.phx.gbl... Jul, In addition to Ken's link on the MailMessage.From property itself.
The System.Web.Mail FAQ (http://www.systemwebmail.net/) has some addition info on the From property (as well as MailMessage itself):
http://www.systemwebmail.net/faq/2.4.aspx
Hope this helps Jay
"Jul" <ju********@sympatico.ca> wrote in message news:zZ*********************@news20.bellglobal.com ... > Hi, > > I use MailMessage class for create email. > > I specify such settings: > mmEmail = New MailMessage > mmEmail.To = ".." > mmEmail.Body = "..." > mmEmail.Subject = "..." > mmEmail.BodyFormat = MailFormat.Text > SmtpMail.SmtpServer = "..." > SmtpMail.Send(mmEmail) > > when I get email send by such code, I can not explain the source of "From" > . > How can I check "FROM" property and change it. > > This question not for "spam" programming. > > Thanks > >
Jul,
What more question:
What are SMTP server are you using? LocalHost, an internal SMTP server, an
external one?
Hope this helps
Jay
"Jul" <ju********@sympatico.ca> wrote in message
news:0d****************@news20.bellglobal.com... Hi ,
Thanks for you answers, but I still have a question. I did not set up "From" property, but it contain value when I get mail. How that property was set up?
"Jay B. Harlow [MVP - Outlook]" <Ja************@msn.com> wrote in message news:#m**************@TK2MSFTNGP15.phx.gbl... Jul, In addition to Ken's link on the MailMessage.From property itself.
The System.Web.Mail FAQ (http://www.systemwebmail.net/) has some addition info on the From property (as well as MailMessage itself):
http://www.systemwebmail.net/faq/2.4.aspx
Hope this helps Jay
"Jul" <ju********@sympatico.ca> wrote in message news:zZ*********************@news20.bellglobal.com ... > Hi, > > I use MailMessage class for create email. > > I specify such settings: > mmEmail = New MailMessage > mmEmail.To = ".." > mmEmail.Body = "..." > mmEmail.Subject = "..." > mmEmail.BodyFormat = MailFormat.Text > SmtpMail.SmtpServer = "..." > SmtpMail.Send(mmEmail) > > when I get email send by such code, I can not explain the source of "From" > . > How can I check "FROM" property and change it. > > This question not for "spam" programming. > > Thanks > >
I use Win 2000 pro
..Net 1.1 - if you need more info about platform I can provide
internal SMTP server - I can not give more information about it, I was just
given "abc.com", so if it is all I know
Sure I can change FROM information as you mentioned previously but it is
interesting the source of my "default" settings
Thansk
"Jay B. Harlow [MVP - Outlook]" <Ja************@msn.com> wrote in message
news:#R**************@TK2MSFTNGP09.phx.gbl... Jul, What more question:
What are SMTP server are you using? LocalHost, an internal SMTP server, an external one?
Hope this helps Jay
"Jul" <ju********@sympatico.ca> wrote in message news:0d****************@news20.bellglobal.com... Hi ,
Thanks for you answers, but I still have a question. I did not set up "From" property, but it contain value when I get mail. How that property was set up?
"Jay B. Harlow [MVP - Outlook]" <Ja************@msn.com> wrote in
message news:#m**************@TK2MSFTNGP15.phx.gbl... Jul, In addition to Ken's link on the MailMessage.From property itself.
The System.Web.Mail FAQ (http://www.systemwebmail.net/) has some
addition info on the From property (as well as MailMessage itself):
http://www.systemwebmail.net/faq/2.4.aspx
Hope this helps Jay
"Jul" <ju********@sympatico.ca> wrote in message news:zZ*********************@news20.bellglobal.com ... > Hi, > > I use MailMessage class for create email. > > I specify such settings: > mmEmail = New MailMessage > mmEmail.To = ".." > mmEmail.Body = "..." > mmEmail.Subject = "..." > mmEmail.BodyFormat = MailFormat.Text > SmtpMail.SmtpServer = "..." > SmtpMail.Send(mmEmail) > > when I get email send by such code, I can not explain the source of "From" > . > How can I check "FROM" property and change it. > > This question not for "spam" programming. > > Thanks > >
This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Trond A. S. Andersen |
last post by:
Hi, all!
I'm trying to use the System.Web.Mail. "package" combinded
with System.Web.Mail.SmtpMail in order to send MS Excel
spreadsheets attached to mail messages. However, sending
one single...
|
by: Mark Rae |
last post by:
Hi,
Can anyone please tell me if it's possible to pass a
System.Web.Mail.MailMessage object to a ASP.NET Web Service? Maybe using XML
Serialization / Deserialization? I've been asked to...
|
by: Phil Mc |
last post by:
Hi has anyone come accross the problem....
with referance to System.Web.Mail.MailMessage and
System.Web.Mail.SmtpMail
THIS WORKS FINE
mail=new MailMessage();
mail.From =...
|
by: martin |
last post by:
Hi,
I have created a class that is totally seperate from my web application.
However this class is used extensivly by the web application for stuff like
data access.
I wish to add a function to...
|
by: Aren Cambre |
last post by:
Why does SmtpMail.Send throw an exception if the MailMessage's
BodyFormat = MailFormat.Html? I've searched all over the place and
cannot find a solution anywhere. I am running this on Windows XP...
| |
by: asnowfall |
last post by:
I am creating MailMessage out of already existing email message.
My existing message has few custom properties. I wan to add them to
System.Net.Mail.MailMessage
How to add custom properties?
...
|
by: asnowfall |
last post by:
I am trying to build System.Mail.MailMessage object out of mime encoded
SMTP data. I have following questions
Byte byteMailData; //mime encoded STMP data for "email with
attachment"
1)...
|
by: Vlad |
last post by:
We are trying to set MailMessage Content-Type to be text/calendar
The following code has been used:
string subject = "Calendar test 3";
MailMessage emailMessage = new MailMessage();...
|
by: =?Utf-8?B?Q2FwdGFpbiBEYXZlIQ==?= |
last post by:
I wrote some code to send an email with two alternate views:
1) html
2) plain text
All the html enabled email clients accept the html just fine and disregard
the plain text version.
However,...
|
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,...
|
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,...
| |
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...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
|
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...
|
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...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
| |
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |