nikhilparchure
Programmer
Hi ,
I have scanning thru on topics of sending mails using
.NET. I have tried the below code for sending mails .
This issue is that mails cannot be sent.
Dim mail As New MailMessage()
mail.To = "tovalidmail@mail.com"
mail.From = "fromvalidmail@mail.com"
mail.BodyFormat = MailFormat.Text
mail.Subject = "Subject of this Email"
mail.Body = "Body of this message."
SmtpMail.SmtpServer = "localhost"
SmtpMail.Send(mail)
-----------------------------
Also no error is displayed but mail is nor sent
Query
1) This code is run on my home PC Win2k server
would the above code be able to send mails using the
local SMTP server on my machine Or does it require
a dedicated Exchange Server setup.
Regards
Parchure Nihkil.
I have scanning thru on topics of sending mails using
.NET. I have tried the below code for sending mails .
This issue is that mails cannot be sent.
Dim mail As New MailMessage()
mail.To = "tovalidmail@mail.com"
mail.From = "fromvalidmail@mail.com"
mail.BodyFormat = MailFormat.Text
mail.Subject = "Subject of this Email"
mail.Body = "Body of this message."
SmtpMail.SmtpServer = "localhost"
SmtpMail.Send(mail)
-----------------------------
Also no error is displayed but mail is nor sent
Query
1) This code is run on my home PC Win2k server
would the above code be able to send mails using the
local SMTP server on my machine Or does it require
a dedicated Exchange Server setup.
Regards
Parchure Nihkil.