System.NET.Mail cannot communicate to relay server through my .net server relay config

Environment:

My PC – I’m testing the code from ServerA in debug mode using VS 2005

ServerA – my .Net Code server in which the code I’m testing resides and is running .NET version 2.0.50727

ServerB – An exchange server on our network

 

Problem & Info:

I get this error no matter if I specify the exchange servername or my .net servername.  I want to use ServerB as the relay server in my System.NET.Mail but when I try that or try just using ServerA’s plain SMTP.  I've used the exchange server fine in other applications from other servers for my code so not sure why it's having such a problem here.

 

My network Admin helped me test the relay to our exchange server in telnet and it successfully works...so this must be a .NET issue at this point.

 

I get this error during debug in VS 2005:

 

http://www.webfound.net/remote_server_error.jpg

 

The VB.NET console code I’m testing:

 

    Private Function SendEmail(ByVal exception_msg As String, ByVal place As String)

 

        Dim fromAddress As New MailAddress("sss@sss.com", "sss Process")

        Dim toAddress As New MailAddress("sss@sss.com", "sss")

        Dim message As New MailMessage(fromAddress, toAddress)

        Dim mailSender As New System.Net.Mail.SmtpClient()

        mailSender.Host = "tried ServerA or ServerB" <---- Problem happens here

 

        message.Subject = "sss Exception"

        message.IsBodyHtml = True

        message.Body = "Error happened in this area" & place & "Error information: " & exception_msg

 

        Try

            mailSender.Send(message)

        Catch ex As Exception

            MsgBox(ex.ToString)

        End Try

 

    End Function

 

Desired Resolution:

I am not sure how to resolve.  I need assistance in what to try.


When is Microsoft going to get rid of VB.NET!
0
dba123
3/23/2006 4:05:50 PM
asp.net.free-for-all 9281 articles. 0 followers. Follow

0 Replies
960 Views

Similar Articles

[PageSpeed] 55

Reply:

Similar Artilces:

What email server or Relay server should I use for a .NET application
I currently use ANSMTP, but it does a DNS lookup and can be very slow.  Is there a better way using .NET? Is there a service that I can send my content that will email it for me.  It seems like managing the email side has just become to hard and sometimes very slow.   Thanks, sorry for the rambling.  you can create a service that will do the emailing for you. there are some approaches for this soln. eg. just write your content in db. let the service read it from db and send email. the service will be scheduled in say every 1 hour. so your web application will only wri...

Mass E-Mail System.Net.Mail.SmtpFailedRecipientException: Insufficient system storage. The server response was: Too many recipients"
hi ,             i am develop a email project in asp.net with vb.net i have client email id in a table having more than 1000 email ids in my project i fetch all the mail id and using for loop i send email to all the eamil id but only 150  email was sent and i got one error "System.Net.Mail.SmtpFailedRecipientException: Insufficient system storage. The server response was: Too many recipients" any body help to solve this bug please.......... Please post your code and we'll see what we can find.&...

Socket communication between Browser and Server in .Net (.Net vs Applet and Servlet in Java)
Any one who know any thing about to make a setup in .Net similar to a Socket communication through Applet and Servlet in Java 2. Reference to papers or literature will be appreciated, or even better some sample code -- preferably in C#. MyLeife...

System.Net.Mail.SmtpClient sends address within apostrophes(single quotes) and the server doesn't recognize server
Hello. I have a page that uses SmtpClient to send a message. the application works perfectly without bugs, but the server returns the following error message: Hi. This is the qmail-send program at smtp2.mailcluster.com.br.I'm afraid I wasn't able to deliver your message to the following addresses.This is a permanent error; I've given up. Sorry it didn't work out.<'******@igf.com.br'>:Sorry, I couldn't find any host named igf.com.br'.  It appears that the "magic" apostrophes that microsoft solved to put around the address messes up everything. The smtp server of this ap...

System.Net.WebException: Unable to connect to the remote server ---> System.Net.Sockets.SocketException: Only one usage of each socket address (protocol/network address/port) is normally permitted
I'm getting this error when hitting a webservice thousands of times for a mass upload. I've researched on the web and added the suggested code but am still getting the error: protected override WebRequest GetWebRequest(Uri uri) { System.Net.HttpWebRequest webRequest = (System.Net.HttpWebRequest)base.GetWebRequest(uri); webRequest.KeepAlive = false; return webRequest; }  Are you receiving it on the client, or on the service?John Saunders | MVP – Connected System Developer...

SQL Server Reporting Services for SQL SERVER 2000 AND Visual Studio.NET 2005 .NET 2.0
Hi, Which version of SQl Server Reporting Services will work with SQL SERVER 2000 in pararrel with ASP.NET 2.0 (.NET 2.0 framework)?  Thanks, Azam HighOnCodingWanna get high! Hi, Okay I got the answer. Yes, we can use the SQL SERVER 2005 Reporting Services with SQL SERVER 2000. HighOnCodingWanna get high! ...

Migration from .net 1.1 to .net 2.0 and deployed in server: error "Server Application Unavilable"
Hi, I have upgraded one .net 1.1 application to .net 2.0. though locally the application is running fine, when deployed in the server it is giving the following error : Server Application Unavailable The web application you are attempting to access on this web server is currently unavailable.  Please hit the "Refresh" button in your web browser to retry your request. Administrator Note: An error message detailing the cause of this specific request failure can be found in the application event log of the web server. Please review this log entry to discover what caused thi...

Value of type 'System.Net.Mail.MailMessage' cannot be converted to 'System.Net.Mail.AlternateView'
Trying to create an alternateview to send a txt email with the html formatted email.  I've used string builder to create the whole email, but I get this error.  Any ideas why?  i've bolded the line that throws the error... Dim EmailBodyTxt As New StringBuilder EmailBodyTxt.Append("<html><style type='text/css'>.table{border:solid; border-color:#006666; width:600;} ")EmailBodyTxt.Append("<body><table class='table'><tr><td colspan='2'><h1>Test<br />RESPONSE SYSTEM</h1></td>...

Net:Net:Net::LDAP::FAQ
------_=_NextPart_001_01C6429F.D89AA417 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Hello, Net::LDAP Net::LDAPS Is there a possible to LDAP bind with an encrypted (SHA, SSHA, CRYPT, ....) password? I don't like to write the secret password to the perl file. Best regards Barbara Wilbert ------_=_NextPart_001_01C6429F.D89AA417-- Wilbert Barbara (CI/OSI) * wrote: > Hello, > > Net::LDAP > Net::LDAPS > > Is there a possible to LDAP bind with an encrypted (SHA, SSHA, CRYPT, > ......

Is my web server 32bit .net or 64bit .net?
If I want to call some .net library to find out what version of .net I'm running, any suggestions on which call to make?Peter Kellnerhttp://73rdstreet.com and blogging athttp://PeterKellner.netMVP, ASP.NET Hi, Would this work for you: http://www.hanselman.com/blog/ProgrammaticallyDetermineWhatVersionOfASPNETYoureRunning.aspxDon't forget to click "Mark as Answer" on the post that helped you. this post does not tell me 32 or 64.Peter Kellnerhttp://73rdstreet.com and blogging athttp://PeterKellner.netMVP, ASP.NET I don't know of any assembly that will tell you that....

System.Net.Mail is giving error CS0029: Cannot implicitly convert type 'string' to 'System.Net.Mail.MailAddress'
I'm getting an error while trying to use the wizard to create a form and than pass it the vaibles to Mail. Any help would be much appreciated. SmtpClient smtpClient = new SmtpClient(); MailMessage message = new MailMessage(); try {   message.From = txtEmail.Text; message.To.Add("admin1@yoursite.com"); message.Subject = "Feedback"; message.CC.Add("admin1@yoursite.com"); message.CC.Add("admin2@yoursite.com"); message.IsBodyHtml = false; message.Body = txtMessage.Text; smtpClient.Send(message); lblStatus.Text = "Email successfully sent."; } catch (Exception ex) { lbl...

E-mail form data using authenticated smtp relay (system.net.mail)?
Hi, out there, I have a set of forms on my site that work fine e-mailing the data back to me with the free e-mail frommy current host, whose smtp relays do not require authentication.  However, there's a tight limit on the number of relays I can have a day.  Due to traffic, I would like my forms now to reference another "From" e-mail, from host with unlimited smtp relays.  Unfortunately, their e-mail requires authentication, and having combed these posts for hours, as well as others, I can't find a working solution to my problem.  It's more...

.net 2 beta 2 - System.Net.Mail
Hi guysI'm using the System.Net.Mail namespace in .net version 2, beta 2, to send out some HTML formatted e-mails.However, for some reason when the e-mail are sent out some of the full stops from the e-mail are removed.For example, part of the e-mail contains this code<img src="http://www.avonandsomerset.police.uk/images/grey_box_bottom.gif" alt="">But this is what the code is like when the e-mail source code is viewed<img src="http://www.avonandsomerset.police.uk/images/grey_box_bottomgif" alt="">Is this a known bug in beta 2? If so, where can I view a list of known bugs an...

system.net.mail not working after server migration
I really have big problems with my CMS-system on EasyCgi. They just changed server and after the migration I can only use system.web.mail  and not system.net.mail. I have a file called errormail.aspx, sending a email to me if there occurs some errors on the site. Sub errormail(strSubject as string, strErrormessage as string) Dim sender As new System.Net.Mail.MailAddress("fejl@mydomain.com") Dim recipient As new System.Net.Mail.MailAddress(myname@myemail.com) Dim msg As New System.Net.Mail.MailMessage(sender,recipient) msg.Subject = strSubject msg....

Web resources about - System.NET.Mail cannot communicate to relay server through my .net server relay config - asp.net.free-for-all

Communicate (Sasha and John Digweed album) - Wikipedia, the free encyclopedia
Communicate is a mix album by Sasha & John Digweed . It is their fifth mix album and the first since 1994 to not be part of the Northern Exposure ...

App Store - Communicate Mate
Get Communicate Mate on the App Store. See screenshots and ratings, and read customer reviews.

New York Speaks: A Hearing on Our Rights to Connect and Communicate - Flickr - Photo Sharing!
credit: Vanissa W. Chan/ACD Media On Monday, Oct. 28 over 100 people gathered to speak out for the open Internet and against the Comcast-Time ...

YouTube - BT - Communicate
Hochgeladen am 13.08.2008 Copyright Disclaimer Under Section 107 of the Copyright Act 1976, allowance is made for "fair use" for purposes such ...

Facebook CEO Mark Zuckerberg says Snapchat 'creates a new kind of space to communicate'
Facebook CEO Mark Zuckerberg has praised Snapchat for creating a new niche for social media communication, calling it a "super interesting privacy ...

Toyota tests cars that communicate with each other
Toyota is testing car safety systems that allow vehicles to communicate with each other and with the roads they are on.

Lego may be a good building block to communicate with autistic children
Incorporating toys such as Lego into autism therapy can make autistic spectrum children more engaged with their peers and increase their social ...

Red faces after firies fail to communicate
Bernard Swann's garage was a raging inferno, its roof had collapsed and his Porsche and Honda cars were already doomed but what happened next ...

Healthway and Carmen: what we have here is failure to communicate
When WA Opera decided that Carmen was not going to be on the program who could have predicted the onslaught of local and national media that ...

Carnivorous plants communicate with bats
A large, meat-eating pitcher plant in Borneo has evolved a unique way to communicate with bats that it hopes to attract.

Resources last updated: 12/5/2015 2:42:07 PM