473,770 Members | 7,213 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

System.Net.Mail .SmtpClient error

MailMessage message = new MailMessage();

message.From = new MailAddress("ak @eka.com.ar","A lejandro");

message.To.Add( "ak@eka.com.ar" );

message.Subject = "Something" ;

message.Body = "Something else";

NetworkCredenti al nc = new NetworkCredenti al("ekaak", "xxx");
SmtpClient mailClient = new SmtpClient("mai l.kwarp.com.ar" , 25);

mailClient.Cred entials = nc;

try

{

mailClient.Send (message);

}

catch (SmtpException ex)

{

Console.WriteLi ne(ex.StatusCod e); // ->GeneralFailu re

}

Any Ideas?

Thanks you
Dec 13 '05 #1
2 1941
Can you specify more details about exception?
Usually SmtpClient in its inner exception contains information such as
HRESULT of underlying layers ( CDO )

There can be great number of reasons why this has happened, only more
details about exception will shed some light

--
Vadym Stetsyak aka Vadmyst
http://vadmyst.blogspot.com

"Alejandro Kwiatkowski" <ak@eka.com.a r> wrote in message
news:%2******** ********@TK2MSF TNGP11.phx.gbl. ..
MailMessage message = new MailMessage();

message.From = new MailAddress("ak @eka.com.ar","A lejandro");

message.To.Add( "ak@eka.com.ar" );

message.Subject = "Something" ;

message.Body = "Something else";

NetworkCredenti al nc = new NetworkCredenti al("ekaak", "xxx");
SmtpClient mailClient = new SmtpClient("mai l.kwarp.com.ar" , 25);

mailClient.Cred entials = nc;

try

{

mailClient.Send (message);

}

catch (SmtpException ex)

{

Console.WriteLi ne(ex.StatusCod e); // ->GeneralFailu re

}

Any Ideas?

Thanks you

Dec 14 '05 #2
One Care Beta is the problem!!

In this thing is necesary to validate the .exe at the firewall on every
build.

Any ideas on how to validate version 1.2.* for example, or the app based in
its location?

Thanks you

"Vadym Stetsyak" <va*****@ukr.ne t> wrote in message
news:u0******** *****@TK2MSFTNG P11.phx.gbl...
Can you specify more details about exception?
Usually SmtpClient in its inner exception contains information such as
HRESULT of underlying layers ( CDO )

There can be great number of reasons why this has happened, only more
details about exception will shed some light

--
Vadym Stetsyak aka Vadmyst
http://vadmyst.blogspot.com

"Alejandro Kwiatkowski" <ak@eka.com.a r> wrote in message
news:%2******** ********@TK2MSF TNGP11.phx.gbl. ..
MailMessage message = new MailMessage();

message.From = new MailAddress("ak @eka.com.ar","A lejandro");

message.To.Add( "ak@eka.com.ar" );

message.Subject = "Something" ;

message.Body = "Something else";

NetworkCredenti al nc = new NetworkCredenti al("ekaak", "xxx");
SmtpClient mailClient = new SmtpClient("mai l.kwarp.com.ar" , 25);

mailClient.Cred entials = nc;

try

{

mailClient.Send (message);

}

catch (SmtpException ex)

{

Console.WriteLi ne(ex.StatusCod e); // ->GeneralFailu re

}

Any Ideas?

Thanks you


Dec 14 '05 #3

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

Similar topics

3
57670
by: HoustonComputerGuy | last post by:
I am working on getting my web applications moved to .Net 2.0 and am having some problems with System.Net.Mail. I get the following error when sending the mail: System.Net.Mail.SmtpException was unhandled by user code Message="Failure sending mail." Source="System" StackTrace: at System.Net.Mail.SmtpClient.Send(MailMessage message) at System.Net.Mail.SmtpClient.Send(String from, String
1
8182
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 the members of my organization. I think my problem is incorrectly setting the settings on my server or an authentication problem. Here is the code I have written to send a test message: -----Code Begins: Sensitive Information Replaced by -----...
2
2165
by: Alex Maghen | last post by:
I want to use the new System.Net.Mail instead of the old System.Web.Mail. I'm getting an error "Hot not specified" when I try to do my last two lines: System.Net.Mail.SmtpClient SMTP = new SmtpClient(); SMTP.Send(Message); //Error happens here But the thing is, in my old use of System.Web.Mail, I never had this problem. Why do I HAVE to specify the host in the new version and I didn't
0
2408
by: howardr101 | last post by:
Hi, Have hunted around on the groups and can't find anything, hence. I've tried this against 2 mail servers (mailtraq and hmailserver) and it occus with both. The problems seems to be that when the SMTPClient attaches to the server and the server sends it greeting message, if anything other than +OK is received by the client it throws an exception and falls over.
2
4321
by: Tim | last post by:
I am trying to send a simple mail message using windows forms in VB.NET 2005. When executing the code, I get a general 'Configuration system failed to initialize' error message when the code instatiates a new MailMessage object (see below) My form has the following code: Imports System.Net.Mail Public Class Form1 Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As
2
17489
by: clevrmnkey | last post by:
I've had nothing but trouble from the System.Net.Mail objects, but I finally need to make them work, and I can't for the life of me see what I'm doing wrong. I pared back my mail transaction to the bare minimum: System.Net.Mail.SmtpClient smtp = new System.Net.Mail.SmtpClient("<my mail server IP>", 25); smtp.Send("<one of my email addresses>", "<another of my email addresses>", "Hello", "World");
1
5164
by: les | last post by:
I'm getting this error "BC30456: 'IsBodyHtml' is not a member of 'System.Net.Mail.SmtpClient'" when trying to submit a form and send email. If I remove the line "MailObj.IsBodyHtml = True" the mail sends without error, but html markup is visible in the body of the email. Any suggestions? Code below:
2
6827
by: satnamsarai | last post by:
Using System.Net.Mail: Sometimes I get error 'failure sending mail. Unable to write data to the transport connection: An existing connection was forcibly closed by the remote host.' Not sure how to fix this error. I am able to send messages sometimes both other times randomly following error appear EXCEPTION:
1
3279
by: WIzmanG | last post by:
Hi all I am having trouble with sending email via a C#2.0 application, I use the same settings as I use in Outlook but I cannot get email to send. I am trying to use SSL on port 465 and get the error below, If I disable SSL and use port 587 all goes well. I have been Googling for 2 days without success and this seems to be a common problem.
5
8331
by: Henry Stock | last post by:
I am trying to understand the following error: Any thing you can tell me about this is appreciated. Security Exception Description: The application attempted to perform an operation not allowed by the security policy. To grant this application the required permission please contact your system administrator or change the application's trust level in the configuration file. Exception Details: for the permission of type
0
9592
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9425
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10230
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10058
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 tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
9870
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
7416
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6678
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
1
3972
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3576
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.