NEED HELP!!!

J

Jay

I have an application that needs to send a confirmation email upon a
completed order. I am using the smptmail obj of .net and can send email to
my companies internal addresses. However, my exchange server (set as the
smart host of my applications smtp server), won't relay to external
addresses. I know the send command is working because of the success of
sending to internal addresses, but I'm trying to figure out what the deal is
with the external forwarding...

Dim oMail As New System.Web.Mail.MailMessage()

oMail.To = SendTo

oMail.From = "(e-mail address removed)"

oMail.BodyFormat = Mail.MailFormat.Text

oMail.Body = strBody

oMail.Attachments.Add(New System.Web.Mail.MailAttachment(strPath,
MailEncoding.Base64))

SmtpMail.SmtpServer = ConfigurationSettings.AppSettings.Item("EmailServer")

SmtpMail.Send(oMail)

SmtpMail.SmtpServer is set to my exchange server.
--
I have also set the smart host of the local smtp server to the exchange
server.

Any help would be hugely appreciated.

Jay Hammett MCSE, MCP + I
President
Fusion Computers
email: (e-mail address removed)
web: www.fusion-computers.com
 
M

Marina

This sounds like a problem with your SMTP server. You have to set it to
allow sending to external addresses. This isn't a .NET issue.
 
J

Jay

Thanks. However I probably didn't give enough info. We're using Exchange
2000 and I was able to send smtp messages using the cdonts objects with a
traditional asp page. I'll look at my smtp server and the exchange box in
the mean time though.
 
D

dave wanta

If you are using cdonts, its actually sending the email through your
local machine's smtp service.

To duplicate this, either leave the SmtpMail.SmtpSever property empty
or set it equal to "127.0.0.1".

hth,
Dave
www.aspNetEmail.com
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,054
Latest member
TrimKetoBoost

Latest Threads

Top