?
Solved

ASP CDO Error with ObjSendMail.CreateMHTMLBody     CDO.Message.1 error '80070005'

Posted on 2007-03-27
3
Medium Priority
?
2,018 Views
Last Modified: 2008-03-10
I am sending an email using CDO via my ASP page. I get this error:

CDO.Message.1 error '80070005'

Access is denied.

/eureka/mailinfo.asp, line 52


Line 52 relates to the ObjSendMail.CreateMHTMLBody line of the code.

- ObjSendMail.CreateMHTMLBody "http://www.xxx.com/eureka/info.asp?id=123"

I have navigated seperately to the page and it works fine.


If I replace Line 52 with

- ObjSendMail.CreateMHTMLBody "http://www.google.com"
OR
- ObjSendMail.CreateMHTMLBody "http://www.xxx.com/eureka/anotherDocument.asp?key=234"

Both works fine.


So there must be an issue with info.asp?id=123... but what causes the system to have problem? JavaScripts? anyone?

0
Comment
Question by:dennisdominic
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 6

Expert Comment

by:sankar_ravi
ID: 18798889
Hi,

You said, if you replace with those two lines, it works fine. But my guess would be try doing this...
Set objConfig = Server.CreateObject("CDO.Configuration")
Set Confi = objConfig.Fields
Confi("http://schemas.microsoft.com/cdo/configuration/sendusing") = 1
Confi("http://schemas.microsoft.com/cdo/configuration/nntpserverpickupdirectory") = "C:\inetpub\mailroot\pickup"
Confi.Update
Set ObjSendMail.Configuration = objConfig
ObjSendMail.To=
xxxxxxxxxxxx
xxxxxxxxxx
etc...
Hope this should work.

In case this fails, try to check for ASP for error free.

Thanks.
0
 
LVL 1

Author Comment

by:dennisdominic
ID: 18798934

I found out why. The directory of
http://www.xxx.com/eureka/
is protected and not accessible. The solution was to move the file info.asp to another directory that is not protected.

I made a mistake in the question.
ObjSendMail.CreateMHTMLBody "http://www.xxx.com/eureka/anotherDocument.asp?key=234" 
Should Not work as well, as it is also in the same directory.

I will award the points later if there's no alternative solution that keeps the file in the same directory as well as allowing permission securely. Can I give permission for just a single file?
0
 
LVL 6

Accepted Solution

by:
sankar_ravi earned 750 total points
ID: 18806011
Yes, Security permission can be given to a particular file in a directory.

Only disadvantage is during later point of time, if you alter the security permissions for the folder, then security permissions for a file will be overwritten.
Applying security permissions for a folder is easier than altering the permission for each and every file.

As a standard means of doing, no one does this unless it is mandatory to do it.

Thanks.
0

Featured Post

NFR key for Veeam Agent for Linux

Veeam is happy to provide a free NFR license for one year.  It allows for the non‑production use and valid for five workstations and two servers. Veeam Agent for Linux is a simple backup tool for your Linux installations, both on‑premises and in the public cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Color can increase conversions, create feelings of warmth or even incite people to get behind a cause. If you want your website to really impact site visitors, then it is vital to consider the impact color has on them.
This article was originally published on Monitis Blog, you can check it here . Today it’s fairly well known that high-performing websites and applications bring in more visitors, higher SEO, and ultimately more sales. By the same token, downtime…
This video teaches users how to migrate an existing Wordpress website to a new domain.
The viewer will learn how to look for a specific file type in a local or remote server directory using PHP.
Suggested Courses

800 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question