Sponsored by
www.aspnetemail.com
|
 |
Discuss This FAQ Item
Got a question? Another Suggestion? Want to post your solution? Discuss it below.
-
Different Exception
[ Reply ]
Hi. I also get the 'scary' message, but the InnerException that I get is totally different. First I have the System.Web.HttpException, whose InnerException is System.Reflection.TargetInvocationException, whose InnerException is System.Runtime.InteropServices.COMException, which doesn't have an InnerException, but it has an HResult property set to -2147219963, that is an MAPI_E_NOT_INITIALIZED error thrown by the CDO.Message.1 object. Any ideas about how to work around this? I was a little confused since I wouldn't expect CDOSYS.dll to rely on MAPI. Thanks in advance and congratulations for your great site.
Rolando Matarrita Sequeira [ rmatarrita ( at ) hotmail dot com ],
2004-02-03 14:42:19
#
-
RE: Different Exception
[ Reply ]
on thing I did find out (and will post as an additional faq item)
Is that if you install Exchange, or anything related to Exchange, the CDOEX.DLL will replace CDOSYS. Which blows up System.Web.Mail. You may want to check to see if this is thhe problem (if you have cdoex.dll installed). If so, you may need to get another copy of the CDOSYS.dll and install it.
Here is translated article discussing this problem.
http://babelfish.altavista.com/babelfish/urltrurl?lp=zh_en&url=http%3A%2F%2Fwww.microsoft.com%2FChina%2FCommunity%2Fprogram%2Foriginalarticles%2FTechDoc%2Fsendmail.mspx
Cheers! Dave
Dave [ dave ( at ) 123aspx dot com ],
2004-02-03 15:34:19
#
-
RE: Different Exception
[ Reply ]
the problem may come if the To and From address are null or not valid. so plz trace all expections
Rupesh [ rkgupta12 ( at ) yahoo dot com ],
2005-08-29 23:06:14
#
-
RE: Different Exception
[ Reply ]
Here's a different solution that helped us.
Go to the SMTP server properties and select the Delivery tab, then click the Advanced button. Enter your relay server name in the Smart Host field.
Also, you might try adding the account under the Security tab under which the CDO.Message object is being used.
BTW, I am setting the SMTPServer property, but that alone (without either of the above actions) does not work.
We run Win 2003 SP1.
HTH
Mike [ jzserai ( at ) state dot pa dot us ],
2005-11-17 08:01:45
#
-
Could not access 'CDO.Message' object
[ Reply ]
Hi, Love your site. I've been hunting high and low for an answer to this. There seems to be many questions on this and very fews answers elsewhere.
Anyway I fixed my problem my looking at the InnerException message. This had a message ' 451 See http://pobox.com/~djb/docs/smtplf.html' This site told me that there was a 'bare LF' without a 'CR', ie. a line-feed without a carriage return. In the message I was sending '\n' without a '\r', so adding a '\r' fixed the error. By the way, I ended up using an html break '<br>' which worked better for me.
Regards, Bryan Stanton
Bryan Stanton [ stantonb ( at ) ihug dot com dot au ],
2004-02-05 15:36:08
#
-
RE: Could not access 'CDO.Message' object
[ Reply ]
Thanks for the kind words.
BTW, here is another gotcha. A lot of people use Environment.NewLine to concat email message lines. DO NOT DO THAT. The Environment.NewLine will output different line terminating chars out, depending upon what system you use. The SMTP spec ONLY allows \r\n (vbCrLf) as line terminating chars.
Besure to code accordingly.
Cheers! Dave
dave [ dave ( at ) 123aspx dot com ],
2004-02-05 15:49:03
#
-
RE RE: Could not access 'CDO.Message' object
[ Reply ]
I am sending nearly 60,000 mails. I ma getting this message after 10 ,000 mails.Could you please help me how to overcome this issue.
Raghav [ pvraghav1976 ( at ) gmail dot com ],
2008-02-23 01:53:41
#
-
RE: Could not access 'CDO.Message' object
[ Reply ]
This one worked for me in VB.NET, found this from a search in google...
turns out you need to set the Relay options in IIS in you default SMTP mail server. I didnt even restart SMTP server and it worked. If it doesnt work for you restart it anyway.
***************************
Open up IIS Admin MMC, find the SMTP Virtual Server, right-click, then select Properties. On the Access tab, click the Relay button. In the Relay Restrictions dialog, grant your IP address (127.0.0.1) to the Computers listbox. You may need to restart the SMTP Service. Also make sure Anonymous access is allowd. This may help...
webgamer [ webgamer ( at ) hotmail dot com ],
2004-09-02 02:07:59
#
-
RE: Could not access 'CDO.Message' object
[ Reply ]
I had the same erro when I was trying to access SMTP server across the network. The problem turned out to be the virus scan program bloacking port 25.
Lizard Man [ lm_one ( at ) hotmail dot com ],
2005-05-20 10:41:24
#
-
RE RE: Could not access 'CDO.Message' object
[ Reply ]
You are the bum man. I found out the mcafee anti-virus I have on my system blocked my sending mails using System.Web.Mail. Thanks for the post.
Lateef [ f3mlat ( at ) yahoo dot com ],
2006-05-31 08:54:21
#
-
RE: Could not access 'CDO.Message' object
[ Reply ]
i m using CDO mail at local host. It is working fine.
But when i uploaded my site on server then it is not sending any mail.
Why ??
Reply soon
<a href="http://www.kkcindia.com"><b>Fun, Humor and Jokes : kkcindia.com</b></a>Get all the Enjoyment and Entertainment with Jokes, quotes,SMS Jokes,Free Games and More!
ka. [ kam ( at ) yahoo dot com ],
2005-06-15 02:13:02
#
-
RE RE: Could not access 'CDO.Message' object
[ Reply ]
dqewwer
asasas [ vivek_cal26 ( at ) yahoo dot com ],
2005-09-06 03:04:49
#
-
RE RE: Could not access 'CDO.Message' object
[ Reply ]
Hi,
I've got the same problem as you. The thing is it's working at other server. Just this particular one (omnis.com). Did you figure out your problem? I'm guessing they block port 25.
Anyway, please let me know if you solved the problem. I'm still waiting for Omnis customer support to reply.
Cheers
Andry
Andry Poernomo [ suencien ( at ) hotmail dot com ],
2005-09-22 22:30:25
#
-
RE: Could not access 'CDO.Message' object
[ Reply ]
Try Out the Mail.SmtpMail.SmtpServer = "" Best of Luck
Chirag [ mr dot patelchirag ( at ) gmail dot com ],
2005-08-08 23:08:20
#
-
RE: Could not access 'CDO.Message' object
[ Reply ]
HOW TO FIND OUT THE SMTP SERVER NAME
thiru [ thirusoft123 ( at ) YAHOOMAIL dot CO dot IN ],
2006-02-09 23:14:52
#
-
RE: Could not access 'CDO.Message' object
[ Reply ]
The smtp server seems to block vblf, change to vbcrlf.
Racialist [ rohitsharma dot aus ( at ) gmail dot com ],
2006-06-15 20:35:02
#
-
RE: Could not access 'CDO.Message' object
[ Reply ]
The first thing everyone should do is check the MailMessage has values for the To, From and all other required fields. Otherwise you'll get this error too.
Ash [ ash ( at ) ash dot com ],
2007-06-29 10:25:36
#
-
RE: Could not access 'CDO.Message' object
[ Reply ]
When one mail send and immediately onether mail is send this mail is put in queue folder . otherwise this will give "Could not access 'CDO.Message' object " Error . so if you can not set your smtpserver or you can use remore smtpserver this will not find Queue folder in C:\Inetpub\mailroot\Queue . When your code is upload on server or you can use local Smtp server then this problem will solve
Mohit Chavda [ mohit_chavda2006 ( at ) yahoo dot com ],
2007-08-16 03:23:33
#
-
RE: Could not access 'CDO.Message' object
[ Reply ]
Hi Friends,
I made the following observation, 1. SendMail() works if u don't add any attachment. 2. It throws an error if we try to send a file which is currently accessed/opened usinf textwriter or file.open(). So either dispose the textwriter or set textwriter to null before invoking Sendmail(). 3. This can be proved by attaching some other file which is not being used by your program and sendmail will work.
Ranjit [ yseriesr ( at ) yahoo dot com ],
2008-02-27 01:02:40
#
-
RE: Could not access 'CDO.Message' object
[ Reply ]
One important observation: A mail with attachment won't be sent if u give a relative path for the file u want to send as attachment. Reason: Program under execution can interpret relative path as it will be w.r.t current directory. But mail cannot interpret a relative path.
Ranjit [ yseriesr ( at ) yahoo dot com ],
2008-03-06 02:32:50
#
-
RE: Could not access 'CDO.Message' object
[ Reply ]
Thanks a lot....
Nit [ nithya dot snair ( at ) gmail dot com ],
2010-02-24 23:19:21
#
-
Could not access 'CDO.Message' object - Unspecified Error
[ Reply ]
Hi Dave
Thank you heaps for the website, it is a true dedication to the class..
I have a intranet aspx page that needs to send via an Exchange server an email WITH attachments.
The problem is this, the application will send attachments of any size if I terminal service onto the box and run it from internet explorer there. When I try to send attachments from ANY other machine on the intranet, if the attachment is more than 100kb in size it will throw the error below.
I know it is not exchange as I can send the email with the same attachment from the server via terminal services. I know it is not permissions as I can still send smaller attachments (under 100kb) with the same name and type from ANY other machine on the network.
The error message as you can see does not give much away as to what the problem is. I was hoping you had some experience with this at some point and may be able to point me in the right direction.
Here is the ERROR:
Error Message: Could not access 'CDO.Message' object.
Error Source: System.Web
Inner Exception: System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.Runtime.InteropServices.COMException (0x80004005): Unspecified error --- End of inner exception stack trace --- at System.RuntimeType.InvokeDispMethod(String name, BindingFlags invokeAttr, Object target, Object[] args, Boolean[] byrefModifiers, Int32 culture, String[] namedParameters) at System.RuntimeType.InvokeMember(String name, BindingFlags invokeAttr, Binder binder, Object target, Object[] args, ParameterModifier[] modifiers, CultureInfo culture, String[] namedParameters) at System.Web.Mail.LateBoundAccessHelper.CallMethod(Object obj, String methodName, Object[] args)
HERE is the code I am using:
private void SendMail(XmlDocument inXML) { //attempt the transform string htmlMsg = String.Empty;
XslTransform xslt = new XslTransform(); xslt.Load(@"\Inetpub\wwwroot\TEST\XSL\TESTEmail.xslt"); StringWriter sw = new StringWriter(); xslt.Transform(inXML, null, sw); htmlMsg = sw.ToString(); sw.Close();
MailMessage msg = new MailMessage(); msg.BodyFormat = MailFormat.Html; msg.To = ConfigurationSettings.AppSettings["EmailTo"]; msg.From = ConfigurationSettings.AppSettings["EmailFrom"]; msg.Subject = "TEST"; msg.Body = htmlMsg; foreach (ListItem li in lbAttachments.Items) { MailAttachment newAtt = new MailAttachment(li.Value, System.Web.Mail.MailEncoding.Base64); msg.Attachments.Add(newAtt); }
SmtpMail.SmtpServer = ConfigurationSettings.AppSettings["SMTPServer"];
SmtpMail.Send( msg );
foreach (ListItem lii in lbAttachments.Items) { try { File.Delete(lii.Value); } catch {} } }
Many thanks for any help you can give..
Ryan.
Ryan [ rowslw ( at ) hotmail dot com ],
2004-04-19 22:30:49
#
-
RE: Could not access 'CDO.Message' object - Unspecified Error
[ Reply ]
so what happens when you iterate through all of the inner exceptions? Do you get any more information?
Cheers! Dave
dave wanta [ dave ( at ) 123aspx dot com ],
2004-04-20 05:37:53
#
-
RE RE: Could not access 'CDO.Message' object - Unspecified Error
[ Reply ]
Thanks for your reply Dave..
Unfortunately there is no more information, i iterated through all the inner exceptions and got the following two only (See Below).
This really has me stumped..
Ryan
Inner Exception: System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.Runtime.InteropServices.COMException (0x80004005): Unspecified error --- End of inner exception stack trace --- at System.RuntimeType.InvokeDispMethod(String name, BindingFlags invokeAttr, Object target, Object[] args, Boolean[] byrefModifiers, Int32 culture, String[] namedParameters) at System.RuntimeType.InvokeMember(String name, BindingFlags invokeAttr, Binder binder, Object target, Object[] args, ParameterModifier[] modifiers, CultureInfo culture, String[] namedParameters) at System.Web.Mail.LateBoundAccessHelper.CallMethod(Object obj, String methodName, Object[] args)
Inner Exception: System.Runtime.InteropServices.COMException (0x80004005): Unspecified error
Ryan. [ rowslw ( at ) homtail dot com ],
2004-04-21 19:35:19
#
-
RE: RE RE: Could not access 'CDO.Message' object - Unspecified Error
[ Reply ]
Something interesting I found.. I downloaded OpenSMTP from the web and gave that a try. First off it looked like it was going to work but when I published it the the offending server it failed.
The point at which it failed was when OpenSMTP attempts to convert the attachment to base64, within the code it uses the method System.IO.Path.GetTempFileName which is of course supposed to return a temporary file name.
This did not happen.. it seems that etiher the security settings or the framework on our servers is not allowing this method to return a temporary file name.
This of course poses the question.. is this method used in the Sysyem.Web.Mail wrapper ? If so this would answer my question on my problem.
Ryan Orsmond [ rowslw ( at ) hotmail dot com ],
2004-04-23 17:09:01
#
-
RE RE: Could not access 'CDO.Message' object - Unspecified Error
[ Reply ]
I have been working on the same error. Here is what I found to cause my error: The domain name had a numeric character in it, ie. xxxx@4xxxxxxx.com I am working on a fix. HTH, Roy
Roy [ rforkner ( at ) monitronics dot com ],
2004-04-29 08:02:53
#
-
451 failed to open files for write
[ Reply ]
Does anybody know this one: ? The following InnerException reported: System.Runtime.InteropServices.COMException (0x8004020E): The server rejected the sender address. The server response was: 451 failed to open files for write
Note the aspnet account has full read/write access to mailroot and subdirs.
JV [ nospam ( at ) heaven dot org ],
2004-04-29 14:12:22
#
-
RE: 451 failed to open files for write
[ Reply ]
i think it also needs write access to winnt\temp and access to the IIS Metabase (can't remember exactly, but I know I documented it on this site, somewhere<g> )
dave wanta [ dave ( at ) 123aspx dot com ],
2004-04-29 14:29:49
#
-
RE RE: 451 failed to open files for write
[ Reply ]
buddy, you need a search engine!
Anyway, I found the solution which I am posting here for the next poor soul that runs into the same problem:
Instead of mailObj.smtpserver = "server name"
use:
mailObj.smtpserver.insert(0,"server name")
This makes absolutely no sense, but it works!!
Bests of luck and thanks for your very usefull site.
JV [ nospam ( at ) heaven dot org ],
2004-04-29 15:52:27
#
-
Believe it or not but suggestion 6 worked for me...
[ Reply ]
Have had horrible time trying to send emails from within a windows service. The inner exception kept saying "System.IO.FileNotFoundException: The specified module could not be found."
Tried heaps of variations and eventually tried it without specifying the smtpserver - it worked! then tried with various different smtpservers - failed!
Remembered the suggestion 6 here and tried it - and it worked!
weird
thanks for a good site
Gerard [ gerardl ( at ) networkpro dot co dot nz ],
2004-05-16 22:22:38
#
-
This solved it for me!
[ Reply ]
Hi,
Thanks for the tips, I wrestled with this problem for months now.
I got a newer version (6.5.6944.0) of CDOEX.DLL from http://www.dynamiclink.nl/frames/dll.htm
This didn't work at first but a closer examination of the inner exception learned that i was using relative paths to create attachments while absolute paths are required.
Works great now!!
Geert-Jan [ g dot thomas ( at ) topskills dot nl ],
2004-06-16 05:43:06
#
-
bare newlines/illegal characters
[ Reply ]
We ran into the cryptic CDO.Message errors because of unnoticed bare newlines that had gotten into the db record data used to construct html emails. What was more aggravating was that the CDO.Message errors were misleading, we thought the issue was a mailserver setting triggering the smtp relay rejections.
Hope this saves your mail server admins some of the headache we gave ours.
Scott [ sfultz ( at ) communityseason dot com ],
2004-06-16 18:18:04
#
-
RE: bare newlines/illegal characters
[ Reply ]
Having the character '\0' in the HTML body caused the could not access 'CDO.Message' in my case. I filtered that character out and the HTML email sent fine.
I hope this helps someone.
Rob [ rtdwyer ( at ) ilstu dot edu ],
2007-08-28 13:39:21
#
-
Re: Suggestion 6
[ Reply ]
This is actually true! I tried all five suggestions and they didn't help and only sixth worked well
Vlad [ vlad ( at ) datlin dot com ],
2004-06-25 06:41:35
#
-
RE Re: Suggestion 6
[ Reply ]
Yes - this one worked for me too, despite the chap in the following thread stating that it has no effect at all. Oh well.
Danny Allen [ danny dot allen ( at ) theedmgroup dot co dot uk ],
2008-08-05 03:35:01
#
-
Suggestion 6
[ Reply ]
Suggestion 6 will not actualy set the value for SmtpServer. This has to do with strings in .net being immutable (cannot be changed after being created). What this means is that when making a call to string.Insert the underlying string that Insert is called on is not changed. The following example will demonstrate this.
Console.WriteLine( "SmtpMail.SmtpServer == '{0}'", SmtpMail.SmtpServer ); SmtpMail.SmtpServer.Insert( 0, "localhost" ); Console.WriteLine( "SmtpMail.SmtpServer == '{0}'", SmtpMail.SmtpServer ); SmtpMail.SmtpServer = "localhost"; Console.WriteLine( "SmtpMail.SmtpServer == '{0}'", SmtpMail.SmtpServer ); SmtpMail.SmtpServer.Insert( 0, "XXXXXXX" ); Console.WriteLine( "SmtpMail.SmtpServer == '{0}'", SmtpMail.SmtpServer );
output: SmtpMail.SmtpServer == '' SmtpMail.SmtpServer == '' SmtpMail.SmtpServer == 'localhost' SmtpMail.SmtpServer == 'localhost'
So, using the method in Suggestion 6 is no different than not setting the SmtpServer property (or setting it to null or string.Empty). Using Lutz Roeders Reflector (http://www.aisto.com/roeder/dotnet/) I was able to see that the following fields are being set on the COM CDO.Message class if the SmptMail.SmtpServer contains a value. (name of field , value assigned)
"http://schemas.microsoft.com/cdo/configuration/sendusing", 2 "http://schemas.microsoft.com/cdo/configuration/smtpserver", [SmtpMail.SmtpServer] "http://schemas.microsoft.com/cdo/configuration/smtpserverport", 25
Joe Sadowski [ joe ( at ) joesadowski dot com ],
2004-07-06 13:22:08
#
-
Mail sending problem fixed.
[ Reply ]
Thanks for the help! Suggestion 6 did the trick.
Misha [ foo ( at ) bar dot com ],
2004-07-15 14:56:46
#
-
RE: Mail sending problem fixed.
[ Reply ]
Even if you believe that the property wont get set it worked fine for me!
Christoph Sinabell [ christoph dot sinabell ( at ) atosorigin dot com ],
2004-07-22 00:22:00
#
-
Could not access 'CDO.Message' object
[ Reply ]
Becareful in using SmtpMail.SmtpServer.Insert( 0, "127.0.0.1 or your mail server name here")
Although the exception is not thrown it does not mean that your email will actually be sent. I tried this method and it is true that the CDO.Message did not get thrown but the email attempt to send outside the company domain did not occur either.
Tom [ norra ( at ) worldnet dot att dot net ],
2004-08-02 08:50:19
#
-
RE: Could not access 'CDO.Message' object
[ Reply ]
I also found this problem...but anyone know the reason?
fi [ ccscelia ( at ) sinagirl dot com ],
2004-08-23 18:43:18
#
-
RE RE: Could not access 'CDO.Message' object
[ Reply ]
I also was getting couldnt access cdo.message error, used #6, and now i am not getting any exceptions, but the email is not getting sent
Steve [ snovoselac ( at ) stcoudwirelessholdings dot com ],
2004-09-07 11:48:26
#
-
RE RE: Could not access 'CDO.Message' object
[ Reply ]
Hi, Here is solution is provided with a code snippet.
smtpmail.smtpserver=<Server Name>
istead use this snippet smtpmail.smtpserver.insert(0,<Here comes server name>) Reason:- It creates instance of smtp server and insert it into smtpmail class and directly create access of SmtpServer instance. this way Access problem is eradicated. Best of luck Zahid Nawaz Ch.
Zahid Nawaz [ znawaz ( at ) acrologix dot com ],
2004-09-29 05:44:34
#
-
THE SOLUTION..
[ Reply ]
Hi! First, i´m from spain so my english y very poor.. excuseme. I found this solution: If you have installed OUTLOOK EXPRESS (i don´t know if in outlook 200x is the same) be sure that in "email count property", in "server" tab, the option "my server requiered autentication" is DISABLED This solve mi problem, i´m working in a big Lan and in same PCs can´t send emails from the app, just the Pcs who´s has this option enabled... Good Luck!! Salu2!!
Ticoadf [ tico_miguel ( at ) hotmail dot com ],
2004-09-10 05:24:44
#
-
RE: THE SOLUTION..
[ Reply ]
Wow, thanks so much! This is what did it for me. I wonder if you can use the authentication set methods described elsewhere in this site to get around having to disable authentication...
Josh [ jwyckoff ( at ) optosystem dot com ],
2005-07-29 16:14:51
#
-
RE: THE SOLUTION..
[ Reply ]
this fixed it for me too. It was trying to use my outlook express default profile to send out.
nathan [ turboneat ( at ) gmail dot com ],
2005-10-17 08:14:33
#
-
RE: THE SOLUTION..
[ Reply ]
This works for me too, but on the other hand, I think Microsoft sucks, why its COM library requires such unreasonable setting??
wkk [ wkk801 ( at ) gmail dot com ],
2005-11-29 18:12:15
#
-
RE: THE SOLUTION..
[ Reply ]
Incredibly it worked with me. it's the second time i find this error, the second one was solved with the 6th option.
Disier [ disier ( at ) gmail dot com ],
2007-04-10 09:19:02
#
-
Could not access 'CDO.Message'
[ Reply ]
i don't have local smtp server.if i run my exe directly on smtp server then its running properly.but if i run the same exe from my local machine then its give the error "Could not access 'CDO.Message'" .i want to know what is the problem.what sholud i do?
regards sanghamitra
sanghamitra [ mitra_panda ( at ) rediffmail dot com ],
2004-09-23 01:26:26
#
-
#5 worked for me. nt
[ Reply ]
n/t
dave g [ dgrant ( at ) brierley dot com ],
2004-09-27 15:41:20
#
-
Could not access 'CDO.Message' object
[ Reply ]
Getting rid of this line msg.BodyFormat = MailFormat.Html; solved it for me.
kisavorobyaninov [ kisavorobyaninov ( at ) hotmail dot com ],
2004-10-01 14:30:38
#
-
Windows Service
[ Reply ]
I was getting the same exception but only under a Windows Service application that I have. In that case I had to make the code that sends the email execute on a secondary (new) thread, otherwise it would crash. Interestingly enough it won't crash every single time but I just couldn't live with that. The solution was to create a helper class with properties for the email message (to, from, body, attachments, etc) with a Send() method and pass the send method as the new Thread start point.
EmailSender email = new EmailSender("joedoe@someserver.com", "myservice@myserver.com", "Look at This", "yada yada yada ..... "); Thread secondaryThread = new Thread(new ThreadStart(email.Send)); secondaryThread.Start();
Sergio Pereira [ tjoker dot removeThis ( at ) bol dot com dot br ],
2004-10-04 06:21:51
#
-
RE: Windows Service
[ Reply ]
I have same scenarion. The mail works fine (10 minutes interval). Suddenly it stops sending the mails with this exception logged in the 'event viewer',
Can you explain your 'fix' (sample code - if possible) please..
Thanks in advance!
SaravanaKumarPaulraj [ tc00455 ( at ) emirates dot com ],
2006-05-08 03:08:32
#
-
Library Not Registered
[ Reply ]
Hi...I have had a look through your suggestions but I am still confused.
I am using system.web.mail to send messages and it has been working fine. The smtpserver was set to my service provider (the same as my outlook setting). All of a sudden, I am getting an InnerException of "Library Not Registered".
Outlook is still sending messages without a problem.
If I am using my ISP SMTP setting, am I correct in assuming that I am not using the SMTP server in IIS on my machine and that any changes made here would have not effect on the problem?
There are 2 things that have changed since my app was last working: 1. Installation of Windows Automatic Updates (Sevice pack 2 Win XP) and 2. Changing from static ip on a WLAN to dynamic. WLAN is connected to a DSL Router. Would any of these be responsible for the problem? My internet connectivity is fine as is the sending and receiving of mail via outlook.
Please help!
Thanks... Jean
Jean [ genie ( at ) saol dot com ],
2004-10-18 01:07:58
#
-
RE: Library Not Registered
[ Reply ]
I had that problem before. Fixed it by running regsrvr32 /u on C:\Program Files\Common Files\Microsoft Shared\CDO\CDOEX.DLL then regsrvr32 on C:\WINNT\system32\cdosys.dll.
paul [ paulfrancis71 ( at ) sbcglobal dot net ],
2005-01-13 14:27:46
#
-
RE RE: Library Not Registered
[ Reply ]
Hello,
We do not have the CDOEX.DLL on our server where I am getting the message about the library not being regsitered. In the registry, CDOSYS.DLL is regsitered for CDO.MESSAGE.
At one time the send email was working on this server.
Any suggestions?
Thank you
K Bickel [ kbickel ( at ) torchmarkcorp dot com ],
2005-05-17 12:24:40
#
-
Error
[ Reply ]
Server: Windows 2000 .Net Framework: v1.1.4322.573
I have this error message occurring on my production server. The production server is also my email server running exchange. I have tried your suggestions above and it still doesn't seem to work. When running on my development server it works fine. I have created a class in asp.net that sends out an email message. It used to work on the production server but now it doesn't? I never made any changes to the application. So, I tried using the application from my machine (development server) and it works fine. I setup both to use the exact same SMTPServer as "mail.whatever.com" and still the developer server works but the production server does not. I tried with the ip address and still no success on the live server. Any ideas? Maybe a service that I should check to see if it is running? The SMTP service is running. Thank you in advance for your help. Is it possible that maybe the CDO dll file is corrupt? If so, how do I replace it?
------------------------------------ ERROR MESSAGE: ------------------------------------ The following exception occurred: System.Web.HttpException: Could not access 'CDO.Message' object. ---> System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.Runtime.InteropServices.COMException (0x80040211): The message could not be sent to the SMTP server. The transport error code was 0x800ccc15. The server response was not available --- End of inner exception stack trace --- at System.RuntimeType.InvokeDispMethod(String name, BindingFlags invokeAttr, Object target, Object[] args, Boolean[] byrefModifiers, Int32 culture, String[] namedParameters) at System.RuntimeType.InvokeMember(String name, BindingFlags invokeAttr, Binder binder, Object target, Object[] args, ParameterModifier[] modifiers, CultureInfo culture, String[] namedParameters) at System.Web.Mail.LateBoundAccessHelper.CallMethod(Object obj, String methodName, Object[] args) --- End of inner exception stack trace --- at System.Web.Mail.LateBoundAccessHelper.CallMethod(Object obj, String methodName, Object[] args) at System.Web.Mail.CdoSysHelper.Send(MailMessage message) at System.Web.Mail.SmtpMail.Send(MailMessage message) at forms._0.Page_Load(Object sender, EventArgs e) -------------------------------- The following InnerException reported: System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.Runtime.InteropServices.COMException (0x80040211): The message could not be sent to the SMTP server. The transport error code was 0x800ccc15. The server response was not available --- End of inner exception stack trace --- at System.RuntimeType.InvokeDispMethod(String name, BindingFlags invokeAttr, Object target, Object[] args, Boolean[] byrefModifiers, Int32 culture, String[] namedParameters) at System.RuntimeType.InvokeMember(String name, BindingFlags invokeAttr, Binder binder, Object target, Object[] args, ParameterModifier[] modifiers, CultureInfo culture, String[] namedParameters) at System.Web.Mail.LateBoundAccessHelper.CallMethod(Object obj, String methodName, Object[] args) -------------------------------- The following InnerException reported: System.Runtime.InteropServices.COMException (0x80040211): The message could not be sent to the SMTP server. The transport error code was 0x800ccc15. The server response was not available
Black Myst [ black_myst ( at ) hotmail dot com ],
2004-11-05 07:19:14
#
-
RE: Error
[ Reply ]
Hi, Your production server cannot connect to the mail server. Something is blocking it. Has a firewall, virus scanner, or something else, been installed that could interupt the network connection?
Cheers! Dave
dave wanta [ dave ( at ) 123aspx dot com ],
2004-11-05 08:20:54
#
-
RE: Error
[ Reply ]
It turned out that a newer version of McAfee Anti-Virus had been installed on the Server, and it blocked port 25 by default. Once we disabled the port blocking, it all started working again.
Black Myst [ black_myst ( at ) hotmail dot com ],
2004-11-05 09:38:26
#
-
Mail issue ..transport lost its connection
[ Reply ]
I am using standard .net code to send emails within a loop.
for .... mail = new MailMessage() mail.from = fromadd mail.Body = body mail.Subject =subject SmtpMail.SmtpServer = "mysmtpserver" SmtpMail.send(mail) mail = nothing next....
Even for just couple of Yahoo addresses I get success on one address and then failure for others
Error: The transport lost its connection to the server.
Point to note is that randomly some emails go through while the rest fail.
Can anyone explain?
Rahul [ rpandhe ( at ) hotmail dot com ],
2004-11-15 10:56:51
#
-
SMTP Send in For...next
[ Reply ]
Hi !
I want to send e-mails to many addresses with different attachments from an ASP.NET application. I use a For..Next cycle to do it. The first e-mail successfully goes out but the others fail with this "Could not access 'CDO.Message' object." error message.
I'm sure the attachment files are exitst and other applications don't lock them. Every mail contains different file as attachment so they cannot lock the attachments of each other.
If I refresh the sender page the very first message goes out again succesfully.
I create a new MailMessage and a new MailAttachment object in each sequence of the For...Next
The only thing that not change is the SmtpMail object. I feel the source of the error from here. Can I initialize it somehow before sending the mails ? Or do you have any other idea what the problem can be ?
Thanks for help in advance !
Jules
Jules Blaidd [ julesbladd ( at ) yahoo dot com ],
2004-11-24 06:57:19
#
-
RE: SMTP Send in For...next
[ Reply ]
Hi, I have the same problem and would like to find a solution from you.
The first e-mail successfully goes out but the others were blocked in smtpmail.send.
regards
JOe [ joe ( at ) glinknet dot com ],
2005-02-24 13:53:25
#
-
another could not access cdocdo.message object
[ Reply ]
Hi,
I'm getting this error as well, and I just can't figure out where the error is originated. I tried just about everything I could find on the internet, including this site.
Can someone take a look at my stack trace to see if you can point me in the right direction? Any help would be greatly appreciated! I'm desperate...
--- Stack Trace --- "System.Web.HttpException: Could not access 'CDO.Message' object. ---> System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.Runtime.InteropServices.COMException (0x80040213): De transportfunctie kan geen verbinding maken met de server.
--- End of inner exception stack trace --- at System.RuntimeType.InvokeDispMethod(String name, BindingFlags invokeAttr, Object target, Object[] args, Boolean[] byrefModifiers, Int32 culture, String[] namedParameters) at System.RuntimeType.InvokeMember(String name, BindingFlags invokeAttr, Binder binder, Object target, Object[] args, ParameterModifier[] modifiers, CultureInfo culture, String[] namedParameters) at System.Type.InvokeMember(String name, BindingFlags invokeAttr, Binder binder, Object target, Object[] args) at System.Web.Mail.LateBoundAccessHelper.CallMethod(Type type, Object obj, String methodName, Object[] args) at System.Web.Mail.LateBoundAccessHelper.CallMethod(Object obj, String methodName, Object[] args) --- End of inner exception stack trace --- at System.Web.Mail.LateBoundAccessHelper.CallMethod(Object obj, String methodName, Object[] args) at System.Web.Mail.CdoSysHelper.Send(MailMessage message) at System.Web.Mail.SmtpMail.Send(MailMessage message) at ConsoleApplication1.Module1.Main() in C:\Documents and Settings\Wouter\My Documents\Visual Studio Projects\ConsoleApplication1\Module1.vb:line 31" --- End Stack Trace ---
Thanks a milion.
El Loco
elloco [ elloco999 ( at ) hotmail dot com ],
2004-12-13 08:14:11
#
-
ta!
[ Reply ]
Thanks for that - it worked a treat.
ben [ ben ( at ) hyl dot co dot uk ],
2005-02-09 14:38:26
#
-
Could not access CDO.Message - A New One
[ Reply ]
Has anyone seen this before?
System.Web.HttpException: Could not access 'CDO.Message' object. ---> System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.Runtime.InteropServices.COMException (0x80040211): The message could not be sent to the SMTP server. The transport error code was 0x800ccc13. The server response was 354 Start mail input; end with <CRLF>.<CRLF>
Shane [ shane ( at ) shanebauer dot com ],
2005-02-14 07:00:46
#
-
Windows 2000 Server with DNS Server
[ Reply ]
I tried everything in the list and almost went back to using the CDONTS object which always worked. After experimenting, here is how I solved the error: 1. Uninstalled SMTP Server 2. Reinstalled SMTP Server 3. Ran Windows Update and updated Outlook Express 4. Applied Suggestion 2 (Relay Permission) 5. Under SMTP Properties, Access Tab, clicked Connection button. 6. Selected "Only the list below" and clicked Add. 7. Typed in 127.0.0.1
Hope this helps.
Josh [ nospam ( at ) yahoo dot com ],
2005-02-27 07:51:46
#
-
The scary "Could not access 'CDO.Message' object"
[ Reply ]
Good afternoon, I'm getting "Could not access 'CDO Message' object" with inner exception: "the 'SendUsing' configuration value is invalid".
I'd appreciate any help. Thanks
pat [ lynchnco ( at ) patmedia dot net ],
2005-02-27 09:40:34
#
-
Doubt about Sending email using SmtpServer
[ Reply ]
Firstly i face the error "ERROR:Could not access 'CDO.Message' object",after visiting ur site & reading solutions this problem is solved. Now code z executing without any error ,but i'm not able to send email successfully.
The VB Code to send email is:
Dim email As New System.Web.Mail.MailMessage() email.To =" urfr_trups@yahoo.com" email.From = "trupti_pandilwar@yahoo.com" email.Body = "Hi!!How r u?" email.Subject = "Hello!" email.BodyFormat = Web.Mail.MailFormat.Text 'System.Web.Mail.SmtpMail.SmtpServer = "127.0.0.1" SmtpMail.SmtpServer.Insert( 0, "127.0.0.1") System.Web.Mail.SmtpMail.Send(email)
What should i do now? Please help me to solve my problem..
Thanks very much.
Trupti Pandilwar [ trupti_pandilwar ( at ) yahoo dot com ],
2005-03-10 05:14:26
#
-
RE: Doubt about Sending email using SmtpServer
[ Reply ]
Be carefull with using the code
SmtpMail.SmtpServer.Insert(0,"127.0.0.1");
In fact, it does not set the SmtpServer property, simply does nothing.
But the Mail.Send() works also in case when the SmptServer property is empty or null, the default SMTP server is used than.
Jakub Snopek [ jakub dot snopek ( at ) ricardo dot com ],
2005-07-11 08:51:27
#
-
RE: Doubt about Sending email using SmtpServer
[ Reply ]
-
RE: Doubt about Sending email using SmtpServer
[ Reply ]
<a href="http://onlinecasino1.000freehosting.com" title="online casino">online casino</a> Find value underlay call mit corner railbirds easy juice pot rolling!
free play online casino games [ hvbyl78 ( at ) alatavissta dot com ],
2006-01-07 08:48:56
#
-
RE: Doubt about Sending email using SmtpServer
[ Reply ]
<a href="http://craps.blog.supereva.it/" title="craps">craps</a> Find rooms hard hearts gang dime shoe shoe pot outdraw lottery outdraw hard lock!
craps [ 6t ( at ) usaa dot com ],
2006-01-10 00:45:43
#
-
RE: Doubt about Sending email using SmtpServer
[ Reply ]
<a href="http://renova.yoll.net/buy-renova-368.html" title="buy cheap renova"> buy cheap renova</a> Also croupier river speek odds paint cap tutorial etiquette ceedy spread straighten racing trips lottery omaha.
buy cheap renova [ 725i ( at ) aquaed dot de ],
2006-01-10 15:19:44
#
-
RE: Doubt about Sending email using SmtpServer
[ Reply ]
<a href="http://sonata.imess.net/cheap-sonata-829.html" title="order cheap sonata"> order cheap sonata</a> If you hanger war omaha free fill house complete face rock carpet.
cheap sonata [ 81ks ( at ) sertifi dot de ],
2006-01-10 23:03:44
#
-
RE: Doubt about Sending email using SmtpServer
[ Reply ]
<a href="http://www.ambien1.dreamstation.com/cheap-ambien-80.html" title="cheap ambien online"> cheap ambien online</a> All table insurance string hold variations semi natural up grinder hearts rank rundown finger buy exotic kings call?
cheap ambien [ 44rtavnek ( at ) usaa dot com ],
2006-01-11 02:48:09
#
-
RE: Doubt about Sending email using SmtpServer
[ Reply ]
<a href="http://www.2hot2cool.com/11/sonata" title="cheap sonata"> cheap sonata</a> Never company beard check glimmer down rooms etiquette pot flat chips fish.
cheap sonata [ 1onpp ( at ) msnn dot com ],
2006-01-11 18:20:22
#
-
RE: Doubt about Sending email using SmtpServer
[ Reply ]
<a href="http://vicodin.undonet.com/online-vicodin-515.html" title="buy online vicodin"> buy online vicodin</a> Never keno spice up spades hanger quads splash bluff pot roulette high picture percentage suit spread?
cheap online vicodin [ 821rgopwnls ( at ) seropo dot ru ],
2006-01-12 07:55:43
#
-
RE: Doubt about Sending email using SmtpServer
[ Reply ]
<a href="http://roulette.home.ph" title="roulette game">roulette game</a> Welcome nuts double tilt punto up third bet deal south outdraw stud slow wiseguy.
roulette game [ 0563gaarrgwp ( at ) smack-56 dot ru ],
2006-01-12 13:43:39
#
-
RE: Doubt about Sending email using SmtpServer
[ Reply ]
<a href="http://roulette.home.ph/615_roulette-game_740.html" title="roulette game">roulette game</a> Before freezeout river main low circle jam profit high neutral kicker ante line keno?
roulette game [ 066whr ( at ) maill dot com ],
2006-01-12 16:57:15
#
-
RE: Doubt about Sending email using SmtpServer
[ Reply ]
<a href="http://xenical1.undonet.com/872_buy-xenical_509.html" title="buy cheap xenical"> buy cheap xenical</a> Each one of flush free easy natural roulette cash neutral rock preferential jam outdraw.
buy xenical online [ 543iptmfom ( at ) maill dot com ],
2006-01-13 22:39:39
#
-
cdo exception
[ Reply ]
Yes indeed after unravelling the inner exception it turned out the mail had simply been rejected.
pat capozzi [ pat dot capozzi ( at ) excell dot com ],
2005-03-17 20:18:53
#
-
RE: cdo exception
[ Reply ]
<a href="http://groups.google.com/group/roulette-online/" title="free roulette"> free roulette</a> Look cheating bingo rounder base event diamonds ceedy coffeehouse hand gross tilt outdraw check?
free online roulette [ 864cgofv ( at ) web12-topl dot de ],
2006-01-07 16:23:53
#
-
RE: cdo exception
[ Reply ]
<a href="http://craps.2itb.com" title="craps">craps</a> Whom bet spikes call airfares railroad crack semi white tapioca progressive mechanic picture face bankroll limit buster site society credit!
craps strategy [ btl27 ( at ) alatavissta dot com ],
2006-01-08 04:21:23
#
-
RE: cdo exception
[ Reply ]
<a href="http://craps1.blogspot.com" title="craps game"> craps game</a> Her up ball clubs set martingale etiquette bust tell split come door equity tell odds!
craps online [ 4499hfm ( at ) web12-topl dot de ],
2006-01-09 06:39:01
#
-
RE: cdo exception
[ Reply ]
<a href="http://retin-a.4t.com" title="retin-a">retin-a</a> Indeed tapioca deck gang represent bust small live third tipping rock hand tutorial bankroll time.
order retin-a [ 095mblyl ( at ) treddmd dot com ],
2006-01-10 04:26:16
#
-
RE: cdo exception
[ Reply ]
<a href="http://ultram.blowsearch.ws" title="ultram">ultram</a> The pineapple kings denomination seven outdraw lottery base credit catch action hole second stand natural buster!
ultram [ 31tsslidn ( at ) gosh dot com ],
2006-01-10 05:31:55
#
-
RE: cdo exception
[ Reply ]
<a href="http://vaniqa.bravehost.com" title="online vaniqa"> online vaniqa</a> Ironically odds up pair pat over championship cheat tapioca zero nuts rake grande street.
buy vaniqa [ 87n ( at ) rosco2344 dot com ],
2006-01-10 09:14:33
#
-
RE: cdo exception
[ Reply ]
<a href="http://renova.yoll.net/" title="buy renova"> buy renova</a> By means of video hard slow tight hard chalk hanger vegas boat time fold rundown shuffling hidden!
renova [ 580lllcpmg ( at ) gmaill dot com ],
2006-01-10 15:05:58
#
-
RE: cdo exception
[ Reply ]
<a href="http://sonata.imess.net/buy-sonata-113.html" title="buy sonata here"> buy sonata here</a> As the video pot flat etiquette apple martingale layout less nuts dollar beef pot apple tap.
buy cheap sonata [ who061 ( at ) usaa dot com ],
2006-01-10 22:45:51
#
-
RE: cdo exception
[ Reply ]
<a href="http://ultram.deep-ice.com/" title="order ultram"> order ultram</a> Any kind of blind flop support first city push goulash banco call banco speek!
buy ultram [ 4399hukoeh ( at ) ssdmmfnf dot com ],
2006-01-12 03:59:50
#
-
RE: cdo exception
[ Reply ]
<a href="http://xenical.hostingrapid.com" title="xenical">xenical</a> As you see underlay price pair rules gang set front push kind hand limit variations trio line.
cheap xenical [ pkpvnypd1537 ( at ) smack-56 dot ru ],
2006-01-12 05:28:32
#
-
Could not access CDO.Message object : html vs text
[ Reply ]
This is my code : MailMessage mail = new MailMessage(); mail.To = "you@destination.be"; mail.From = "me@mylocation.be"; mail.Subject = "mysubject "; mail.BodyFormat = MailFormat.Html; mail.Body = "hello world"; SmtpMail.SmtpServer = "myserver"; SmtpMail.Send(mail);
When i run this code from a console application it works fine in both MailFormat.Html and MailFormat.Text format, but when i run it from an aspx page i can only use MailFormat.Text format. In MailFormat.Html format I get the "Could not access CDO.Message object" eror. I have already tried to put html and body tags around my text but this does not help. It is driving me crazy ! Any suggestions ?
If it is of any use, this is the innerexeption : The following exception occurred: System.Web.HttpException: Could not access 'CDO.Message' object. ---> System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.Runtime.InteropServices.COMException (0x80040605): Unknown Error --- End of inner exception stack trace --- at System.RuntimeType.InvokeDispMethod(String name, BindingFlags invokeAttr, Object target, Object[] args, Boolean[] byrefModifiers, Int32 culture, String[] namedParameters) at System.RuntimeType.InvokeMember(String name, BindingFlags invokeAttr, Binder binder, Object target, Object[] args, ParameterModifier[] modifiers, CultureInfo culture, String[] namedParameters) at System.Type.InvokeMember(String name, BindingFlags invokeAttr, Binder binder, Object target, Object[] args) at System.Web.Mail.LateBoundAccessHelper.SetProp(Type type, Object obj, String propName, Object propValue) at System.Web.Mail.LateBoundAccessHelper.SetProp(Object obj, String propName, Object propValue) --- End of inner exception stack trace --- at System.Web.Mail.LateBoundAccessHelper.SetProp(Object obj, String propName, Object propValue) at System.Web.Mail.CdoSysHelper.Send(MailMessage message) at System.Web.Mail.SmtpMail.Send(MailMessage message) at deschutter.com.PackFlow.Web.InviteApprovers.SendMail(String toList, String pdfUrl) in c:\inetpub\wwwroot\packflow\inviteapprovers.aspx.cs:line 77--------------------------------The following InnerException reported: System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.Runtime.InteropServices.COMException (0x80040605): Unknown Error --- End of inner exception stack trace --- at System.RuntimeType.InvokeDispMethod(String name, BindingFlags invokeAttr, Object target, Object[] args, Boolean[] byrefModifiers, Int32 culture, String[] namedParameters) at System.RuntimeType.InvokeMember(String name, BindingFlags invokeAttr, Binder binder, Object target, Object[] args, ParameterModifier[] modifiers, CultureInfo culture, String[] namedParameters) at System.Type.InvokeMember(String name, BindingFlags invokeAttr, Binder binder, Object target, Object[] args) at System.Web.Mail.LateBoundAccessHelper.SetProp(Type type, Object obj, String propName, Object propValue) at System.Web.Mail.LateBoundAccessHelper.SetProp(Object obj, String propName, Object propValue)--------------------------------The following InnerException reported: System.Runtime.InteropServices.COMException (0x80040605): Unknown Error
martin devos [ martind ( at ) deschutter dot be ],
2005-03-30 06:41:28
#
-
RE: Could not access CDO.Message object : html vs text
[ Reply ]
I have the same problem!
Could not access CDO.Message object when the body format is HTML! With body format TEXT everything works fine!
This is ridiculous!
Damir Colak [ dcolak ( at ) colaksoft dot com ],
2006-04-05 17:21:43
#
-
RE RE: Could not access CDO.Message object : html vs text
[ Reply ]
Found a solution to this one. I made sure it was nothing that was mentioned so far. Then i unregistered cdosys.dll, closed my dev environment, restarted IIS Admin server (recycles www, https, and smtp services). Then registered the DLL and restarted IIS Admin again. Then for some reason it all worked!
Windowns [ com ( at ) com dot com ],
2006-07-21 17:09:41
#
-
SmtpMail.SmtpServer.insert solved the problem and an explanation
[ Reply ]
Hi All,
This is the first time I had a CDO issue with my VB.NET just on ONE server. I was not getting an authentication issue, but a transport issue. Using the Insert command fixed it straight away, then I realised why. This server did not have any Outlook or other mail program other than Outlook Express. OE was not setup to point to an smtp server. When I was doing the usual SmtpMail.SmtpServer = "127.0.0.1" is was actually adding the address onto the mail server index (you can find the Index 0 setting in the regitry), and trying to send mail out the "invalid" or index 0 smtp entry. By inserting the valid smtp server into index 0, it works.
Robear [ robear ( at ) joshie dot com dot au ],
2005-04-12 20:00:13
#
-
Two things made CDO work!
[ Reply ]
After trying every suggestion and combination this is what we found finally worked for us (we use Remoting and our own ASPNET machine account). Try this:
1. Don't set the SMTP server (SmtpMail.SmtpServer), it's the same as using the suggested SmtpMail.SmtpServer.Insert(0, "127.0.0.1"). Just call SmtpMail.Send()
2. Set write permissions for the ASPNET machine account (or whatever account defined in machine.config) on the inetpub\mailroot folder.
Someone suggested to alter the metabase and set read permission, we tried that and it didn't help, but it could according to Microsoft: "No special permissions are required to run interactive applications or ASP pages to enable use of CDOSYS. In applications that use the SMTP or NNTP drop-directory, the application or user must have permission to write into that directory. When running an application that sends e-mail, the user will require either write access to the pick-up directory, or read access to the IIS metabase so the application can determine the SMTP port used for sending mail."
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/e2k3/e2k3/_techsel_criteria_20.asp
frasse [ lisse ( at ) sverige dot nu ],
2005-04-21 09:44:40
#
-
Sending mail from asp.net
[ Reply ]
Hi check my link here.
http://spaces.msn.com/members/devicharan/
you have solution there
could not access cdo.message object [ devicharan dot vinnakota ( at ) majoris dot com ],
2005-04-27 22:48:14
#
-
email sending with attachment pdf file above 100kb size
[ Reply ]
i m sending email with attaching pdf file greater than 100 kb size and it will give me error unspecified error plz solve my prob immediately
ashwini [ ashwini_svartak ( at ) hotmail dot com ],
2005-05-06 01:19:45
#
-
RE: email sending with attachment pdf file above 100kb size
[ Reply ]
Hi,
This site is terrific! Thank you so much for the help!! I am having the same problem. When I try SmtpMail.Send with a small (attached) file (20K) everything works fine but when it's a larger file (9MB) it fails with:
The message could not be sent to the SMTP server. The transport error code was 0x800ccc13. The server response was not available.
Here is some of the stack trace info: -------------------------------- Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.Runtime.InteropServices.COMException: The message could not be sent to the SMTP server. The transport error code was 0x800ccc13. The server response was not available
Source Error:
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.
Stack Trace:
[COMException (0x80040211): The message could not be sent to the SMTP server. The transport error code was 0x800ccc13. The server response was not available ]
[TargetInvocationException: Exception has been thrown by the target of an invocation.] System.RuntimeType.InvokeDispMethod(String name, BindingFlags invokeAttr, Object target, Object[] args, Boolean[] byrefModifiers, Int32 culture, String[] namedParameters) +0 System.RuntimeType.InvokeMember(String name, BindingFlags invokeAttr, Binder binder, Object target, Object[] args, ParameterModifier[] modifiers, CultureInfo culture, String[] namedParameters) +473 System.Web.Mail.LateBoundAccessHelper.CallMethod(Object obj, String methodName, Object[] args) +58
[HttpException (0x80004005): Could not access 'CDO.Message' object.] System.Web.Mail.LateBoundAccessHelper.CallMethod(Object obj, String methodName, Object[] args) +111 System.Web.Mail.CdoSysHelper.Send(MailMessage message) +1863 System.Web.Mail.SmtpMail.Send(MailMessage message) +150 ----------------------------------- I did set the "Limit message size to (KB)" and "Limit sessioni size to (KB)" SMTP fields to 12288, and restarted the SMTP service. Same results.
Any ideas would be greatly appreciated!
Thanks.
Larry
Larry Ouellette [ larry dot ouellette ( at ) hp dot com ],
2005-07-07 11:06:34
#
-
What I learned
[ Reply ]
I tried a lot of what you said here and found a few things out, the SmtpMail.SmtpServer.Insert( 0, mailServer) appears to just use the local host (default) SMTP server I guess it works for a lot of people because there local server is setup differently to their mail server.
The following seemed to be the most robust setting for mailing from ASP.NET for me.
SmtpMail.SmtpServer = mailServer; MailMessage mailMessage = new MailMessage(); mailMessage.BodyFormat = MailFormat.Text ; mailMessage.From = from; mailMessage.To = recipient; mailMessage.Subject = subject; mailMessage.Body = body;
mailMessage.Headers.Add("Reply-To",from); mailMessage.Fields.Add("http://schemas.microsoft.com/cdo/configuration/smtpconnectiontimeout", 60); mailMessage.Fields.Add("http://schemas.microsoft.com/cdo/configuration/smtpauthenticate", "1"); mailMessage.Fields.Add("http://schemas.microsoft.com/cdo/configuration/sendusername", username); mailMessage.Fields.Add("http://schemas.microsoft.com/cdo/configuration/sendpassword", password);
SmtpMail.Send(mailMessage);
The mail server in this case is an exchange server.
This info was snatched from http://www.devnewsgroups.net/group/microsoft.public.dotnet.framework/topic11061.aspx
D
Great site, it was invaluable.
David [ dsmith ( at ) origin-data dot co dot uk ],
2005-05-09 09:11:03
#
-
This was the solution!
[ Reply ]
Can somebody explain why that works?
David [ profnachos ( at ) yahoo dot com ],
2005-05-10 13:24:36
#
-
VirusScan
[ Reply ]
By default, VirusScan in its infinite wisdom blocks SMTP from unknown apps. To shut this off, go to the VirusScan console and uncheck the SMTP rule.
Michael Carr [ mcarr ( at ) umich dot edu ],
2005-05-21 17:41:46
#
-
RE: VirusScan
[ Reply ]
This also fixed my problem. Turning "On Access Scan" off for McAffee AV 8.0i allows the emails to go out. Unchecking "Prevent Mass Mailing worms from sending email" will unblock port 25, allowing emails to go out. Thinking about this more, anything that can block port 25 would probably cause your application to fail. So check your firewalls too!
Daniel Jue [ djue ( at ) isr dot umd dot edu ],
2005-08-23 10:36:08
#
-
Running On Desktop
[ Reply ]
After many hours of looking through everybodies answers I didnt see anything that had to do with a Desktop solution. So here is what i did to get mine working;
You have to uninstall Outlook express. Reinstall it then register the cdosys.dll
In the run command; regsvr32 "c:\WINDOWS\system32\cdosys.dll
Michael McMullen [ plasma_z ( at ) mail dot com ],
2005-06-04 12:23:13
#
-
The scary "Could not access 'CDO.Message' object"
[ Reply ]
Greetings, all:
I thought I would offer up something that worked for us here, that I did not see in all the discussions.
Our company uses an enterprise edition of McAfee AntiVirus. This means on every computer in the building, there are two little icons in the system tray that look like roman shields, and all their menu items are disabled by administrative domain policy so that we cannot reconfigure them in any way.
Turns out, McAfee was blocking TCP 25 Outbound on our computers. (We use Outlook / Exchange for mail here, which uses MAPI over RPC ports).
So I goto Administrative Tools -> Services and disable the three "McAfee" and "Network Associates" related services, and presto, my code can send an SmtpMail.
Peace & stuff!
Mike Labosh, MCSD "Escriba coda ergo sum." -- vbSensei
Mike Labosh [ mlabosh ( at ) hotmail dot com ],
2005-06-17 13:18:00
#
-
Simplest Way to send a mail in VB.NET
[ Reply ]
I have tried the code below and it is working: BN: I am using VB.NET with VS.NET Architect 2003
1. Add the COM reference "Microsoft ActiveX Data Objects 2.8 Library" 2. Add the COM reference "Microsoft CDO for Windows 2000 Library" or browse it at "c:\windows\system32\cdosys.dll" 3. Use the following sub to send your message. Provide the required parameters:
Public Sub SendMail(Byval AdrFrom As String ByVal AdrTo As String, ByVal AdrCC As String, ByVal MailBody As String)
Try Dim oMessage As CDO.Message 'Create a Message Object oMessage = CreateObject("CDO.Message")
With oMessage 'Set the properties .To = AdrTo .From = AdrFrom .TextBody = MailBody .Subject = "Reminder: Actions to take for listed Staff" .Configuration.Fields.Item("CdoSendUsing").Value = CDO.CdoSendUsing.cdoSendUsingPickup 'Using Exchange Server .Configuration.Fields.Update() .Send() End With Catch ex As Exception Console.WriteLine(ex.Message) End Try End Sub
I hope this will help many of you.
Gildas Makaya [ makayag ( at ) afro dot who dot int ],
2005-06-22 04:19:14
#
-
Could not access 'CDO.Message' object
[ Reply ]
I had this problem and found that The .Net library use the default e-mail account for sending e-mail. Setting correct e-mail account as default e-mail account in outlook express resolved my problem.
Kashif Mushtaq [ kashifmushtaqpak ( at ) yahoo dot com ],
2005-07-06 15:48:42
#
-
Problem in sending mail"Could not access 'CDO.Message' object"
[ Reply ]
Dear Sir We r from dimensionslive.com and we have a problem in sending mail from our subdomain "gotopoints.dimensionslive.com" but this mailing sevice is working smoothly in our local Server.Please give me ur suggestion to how can i sove this problem?
we r getting an error that i iveb bellow
System.Web.TraceContextSystem.Web.TraceContext
System.Web.TraceContext
Could not access 'CDO.Message' object.Customer at System.Web.Mail.LateBoundAccessHelper.CallMethod(Object obj, String methodName, Object[] args) at System.Web.Mail.CdoSysHelper.Send(MailMessage message) at System.Web.Mail.SmtpMail.Send(MailMessage message) at GoToPoints.Business.GiftCertificate.mailtoCustomer() in c:\inetpub\wwwroot\gotopoints\business\giftcertificate.aspx.cs:line 96
System.Web.TraceContext Could not access 'CDO.Message' object.business at System.Web.Mail.LateBoundAccessHelper.CallMethod(Object obj, String methodName, Object[] args) at System.Web.Mail.CdoSysHelper.Send(MailMessage message) at System.Web.Mail.SmtpMail.Send(MailMessage message) at GoToPoints.Business.GiftCertificate.mailtoBusinessOwner() in c:\inetpub\wwwroot\gotopoints\business\giftcertificate.aspx.cs:line 64 Thankyou Rakesh Sankar
Rakesh [ rakeshsankar007 ( at ) yahoo dot co dot in ],
2005-07-12 00:35:32
#
-
Library not registered - CDO ( Urgent Help )
[ Reply ]
My sending mail logic is built into a .net library dll. When invoked from a Windows application built using .NET the sending mail works. When invoked from a asp.net web application it fails with the following error. I have gone through all your articles and found that only cdosys.dll is loaded. But still get this error.
Library not registered. Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and w |