How are you sending the email? Its very easy to send email from .Net using
the System.Messaging namespace.
Here's a sample
Dim oMessage As New System.Web.Mail.MailMessage()
oMessage.To = "An*******@ADomain.com"
oMessage.From = "My*****@MyDomain.com"
oMessage.Subject = "A New Email Message"
oMessage.Body = "I hope you get this email! I’ll talk to you later!"
' This part is required if your mail server requires authenticatio
oMessage.Fields.Item("http://schemas.microsoft.com/cdo/configuration/sendusing") = 2
oMessage.Fields.Item("http://schemas.microsoft.com/cdo/configuration/smtpserver") = "mail.sendmail.com
oMessage.Fields.Item("http://schemas.microsoft.com/cdo/configuration/sendusername") = "My*****@MyDomain.com
oMessage.Fields.Item("http://schemas.microsoft.com/cdo/configuration/sendpassword") = "MyPa$$word"
oMessage.Fields.Item("http://schemas.microsoft.com/cdo/configuration/smtpauthenticate") = 1
System.Web.Mail.SmtpMail.SmtpServer = "mail.sendmail.com"
Try
System.Web.Mail.SmtpMail.Send(oMessage)
Response.Write("Email sent!")
Catch Ex As Exception
Response.Write("Unable to send mail! " & Ex.Message)
End Try
I hope this helps.
"John" wrote:
Having a problem sending emails through vb.net. Our inhouse software
automatically sends an email to the programming staff whenever an error is
encountered.
This code works just fine on machines that are windows 2000 based. We
recently upgraded from Outlook 2000 to Outlook 2003, and it still works.
We have one machine with XP service pack 1. It works fine there. This also
was upgraded from outlook 200 to outlook 2003.
On two new machines, we have XP Service Pack 2. They came with outlook 2003,
so no upgrade was needed. On these machines, we get an error stating that
"modAgentSys can not create activex component" which then crashes the program.
Any ideas?