473,406 Members | 2,273 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,406 software developers and data experts.

Sending Mail to an External Email Address

The following code works when sending to an email address that resides
on our Exchange domain. However, when trying to send to an External
domain it does not work. The folling is the "doesn't work" code:

Dim oMsg As MailMessage = New MailMessage()

oMsg.From = "jo******@abc.com"
oMsg.To = "jo*******@yahoo.com"
oMsg.Subject = "This does not work"
oMsg.Body = "Does anyone have a solution"

SmtpMail.SmtpServer = "ABC.EXCHANGE.COM"
SmtpMail.Send(oMsg)
I believe there might be someing on IIS that needs to be set. Any help
is appreciated.

Thank you,
Elliot Semmelman
Jul 21 '05 #1
2 1988
Hello Elliot

I just tested some code from a VB App using the SMPT mail object and
successfully sent emails out on a server outside our local net.

So it works. In fact, the Email server I used is on the net. Across
firewalls etc.

Check to see if Port 25 is blocked somewhere in your tcp/ip path.

Maybe your firewall blocks port 25 ?


--
Ibrahim Malluf
http://www.malluf.com
==============================================
MCS Data Services Code Generator
http://64.78.34.175/mcsnet/DSCG/Announcement.aspx
==============================================


"Elliot" <es********@afgweb.com> wrote in message
news:e5**************************@posting.google.c om...
The following code works when sending to an email address that resides
on our Exchange domain. However, when trying to send to an External
domain it does not work. The folling is the "doesn't work" code:

Dim oMsg As MailMessage = New MailMessage()

oMsg.From = "jo******@abc.com"
oMsg.To = "jo*******@yahoo.com"
oMsg.Subject = "This does not work"
oMsg.Body = "Does anyone have a solution"

SmtpMail.SmtpServer = "ABC.EXCHANGE.COM"
SmtpMail.Send(oMsg)
I believe there might be someing on IIS that needs to be set. Any help
is appreciated.

Thank you,
Elliot Semmelman

Jul 21 '05 #2
Thank you for your reply. I've checked with our network people and they say
that Port 25 is not blocked. I can send it externally from Microsoft Outlook
and also using VB6 code. Still scratching my head.
"IbrahimMalluf" <Ib*****@malluf.com> wrote in message
news:ed**************@TK2MSFTNGP12.phx.gbl...
Hello Elliot

I just tested some code from a VB App using the SMPT mail object and
successfully sent emails out on a server outside our local net.

So it works. In fact, the Email server I used is on the net. Across
firewalls etc.

Check to see if Port 25 is blocked somewhere in your tcp/ip path.

Maybe your firewall blocks port 25 ?


--
Ibrahim Malluf
http://www.malluf.com
==============================================
MCS Data Services Code Generator
http://64.78.34.175/mcsnet/DSCG/Announcement.aspx
==============================================


"Elliot" <es********@afgweb.com> wrote in message
news:e5**************************@posting.google.c om...
The following code works when sending to an email address that resides
on our Exchange domain. However, when trying to send to an External
domain it does not work. The folling is the "doesn't work" code:

Dim oMsg As MailMessage = New MailMessage()

oMsg.From = "jo******@abc.com"
oMsg.To = "jo*******@yahoo.com"
oMsg.Subject = "This does not work"
oMsg.Body = "Does anyone have a solution"

SmtpMail.SmtpServer = "ABC.EXCHANGE.COM"
SmtpMail.Send(oMsg)
I believe there might be someing on IIS that needs to be set. Any help
is appreciated.

Thank you,
Elliot Semmelman


Jul 21 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
by: Owen | last post by:
I am sending email using CDO but it only seems to work when the "To" address is within the same domain as mine. When I send to an outside domain (eg. yahoo.com) the mail simply does not reach...
12
by: Joe_Black | last post by:
Hi all, I have googled this and found some answers but none that give me exactly what I'm after, maybe someone here can help. I have an app that will be distributed to users for their laptop...
3
by: VB Programmer | last post by:
I have an ASPX page where I send out emails through my mail server mail.MyDomain.com. When I send emails to MyName@MyDomain.com it sends PERFECTLY. When I try sending an email to any other address...
6
by: Robert Pettersson | last post by:
Hi, I have built an webapp in C# that uses SMTPMail to send mail to users. When I installed it on the prodserver everything worked fine for me, but the users can not send mail. They get Access...
2
by: Elliot | last post by:
The following code works when sending to an email address that resides on our Exchange domain. However, when trying to send to an External domain it does not work. The folling is the "doesn't work"...
3
by: Ant | last post by:
Hi, I'm using the MailMessage & smtpMail classes in System.Web.Mail to send mail, however it's not sending any emails. I'm using it on a Windows 2003 server. The simplest way to use this is...
6
by: Anuradha | last post by:
Dear All How can i send mails using vb.net Thanx all
1
by: Eric Sheu | last post by:
Greetings, I have been searching the web like mad for a solution to my SMTP problem. I am using Windows Server 2003 and ASP.NET 2.0 w/ C# to send out e-mails from a web site I have created to...
7
by: undbund | last post by:
Hi I am creating a newsletter system. The software should run from desktop computer (localhost) but be able to send email to anyone on the internet. Can you guys give me some ideas on how to...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
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
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
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
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...
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,...

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.