473,508 Members | 2,104 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Could not access CDO.Message

I'm using System.Web.Mail to generate e-mails and I'm adding attachments.
When I add a ~300KB *.doc file, it works as expected. When I attached a 1.2
MB PDF File, I get the following exception:

Any thoughts?

? ex.InnerException

{System.Reflection.TargetInvocationException}

[System.Reflection.TargetInvocationException]:
{System.Reflection.TargetInvocationException}

HelpLink: Nothing

InnerException: {System.Runtime.InteropServices.COMException}

Message: "Exception has been thrown by the target of an invocation."

Source: "mscorlib"

StackTrace: " 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(T ype type, Object obj,
String methodName, Object[] args)

at System.Web.Mail.LateBoundAccessHelper.CallMethod(O bject obj, String
methodName, Object[] args)"

TargetSite: {System.Reflection.RuntimeMethodInfo}
Nov 9 '05 #1
1 2138
Is this possibly related to the max size for messages that is set in your
IIS SMTP server?

IIS Admin -> Default SMTP Virtual Server -> Properties -> Message Tab

The default on my Win Xp box is set at 10240K. You are exceeding that.

-Andrew
"James" <mi*******@gmail.com> wrote in message
news:OU**************@TK2MSFTNGP15.phx.gbl...
I'm using System.Web.Mail to generate e-mails and I'm adding attachments.
When I add a ~300KB *.doc file, it works as expected. When I attached a
1.2 MB PDF File, I get the following exception:

Any thoughts?

? ex.InnerException

{System.Reflection.TargetInvocationException}

[System.Reflection.TargetInvocationException]:
{System.Reflection.TargetInvocationException}

HelpLink: Nothing

InnerException: {System.Runtime.InteropServices.COMException}

Message: "Exception has been thrown by the target of an invocation."

Source: "mscorlib"

StackTrace: " 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(T ype type, Object obj,
String methodName, Object[] args)

at System.Web.Mail.LateBoundAccessHelper.CallMethod(O bject obj, String
methodName, Object[] args)"

TargetSite: {System.Reflection.RuntimeMethodInfo}

Nov 9 '05 #2

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

Similar topics

5
11006
by: Tim Eliot | last post by:
Just wondering if anyone has hit the following issue and how you might have sorted it out. I am using the command: DoCmd.TransferText acExportMerge, , stDataSource, stFileName, True after...
2
7255
by: Desmond | last post by:
Hi, I would really appreciate if somebody could give some advise on this. I've a ASP.NET application that is supposed to send emails and it is tested to be working well on IIS 5.0 and tested...
4
2060
by: Lynn | last post by:
hi, anyone knows how to fix this error? Event Type: Error Event Source: ASP.NET 1.0.3705.288 Event Category: None Event ID: 1082 Date: 1/18/2004 Time: 12:50:47 AM User: N/A
1
2688
by: Jens Øster | last post by:
Hi I am writing a ASP.NET web application that must sent some e-mails. I get the exception “Could not access 'CDO.Message' object” when I call SmtpMail.Send. This only happens when I send...
3
9242
by: Jens | last post by:
Hi I am writing a ASP.NET web application that must sent some e-mails. I get the exception “Could not access 'CDO.Message' object” when I call SmtpMail.Send. This only happens when I send...
4
3959
by: Liz Patton | last post by:
Here's the exception: System.Exception: Unable to send mail: Could not access 'CDO.Message' object. ---> System.Web.HttpException: Could not access 'CDO.Message' object. --->...
2
604
by: Martin | last post by:
Hi, I have standard code that sends mail from an asp.net application. The application is running on a production web server. it uses the standard system.web.mail namespace. most of the time...
14
9353
by: Gianfranco | last post by:
Hi everybody, First of all, sorry for my english if it isn't perfect ;-p I have an error in an asp.net application. I have win2003 server, with iis 6. I'm developping with visual studio...
8
30792
by: hufaunder | last post by:
I have a website that consumes a webservice. Both of them are in the Default Website folder. I can execute the service without any problem when I go to the test page http://localhost/Service.asmx....
11
4986
by: fniles | last post by:
One of our application uses VB6 and Access97 database. Another application uses VB.NET 2005. This morning for about 15 seconds when the application tries to read either a query or a table from the...
0
7226
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,...
0
5631
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 projectplanning, coding, testing,...
1
5055
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...
0
4709
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...
0
3199
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
3186
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1561
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 ...
1
767
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
422
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

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.