Web Wiz - Green Windows Web Hosting

  New Posts New Posts RSS Feed - error in snapshot generating code (asp)
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

error in snapshot generating code (asp)

 Post Reply Post Reply
Author
vinodkalpaka View Drop Down
Newbie
Newbie


Joined: 19 July 2004
Location: India
Status: Offline
Points: 3
Post Options Post Options   Thanks (0) Thanks(0)   Quote vinodkalpaka Quote  Post ReplyReply Direct Link To This Post Topic: error in snapshot generating code (asp)
    Posted: 19 July 2004 at 1:30am

hi

i have a problem with devoloping an asp program ,that is  dynamically generating snapshot files (in .snp format)from

a MS-access database.
database name is datafile.mdb.
Report name is "reportTarge".
here is the asp code for this.


<%
    Dim objAccess
    Set objAccess = Server.CreateObject("Access.Application")
        objAccess.OpenCurrentDatabase request("APPL_PHYSICAL_PATH") & "databasename.mdb"
    objAccess.DoCmd.OutputTo 3, "reportName", "Snapshot Format (*.snp)", "snapshotname.snp", 0
    objAccess.DoCmd.Quit 2
%>

 

But while executing this asp code ,i am getting the following error in my IE browser.

Error Type:
Server object, ASP 0178 (0x80070005)
The call to Server.CreateObject failed while checking permissions. Access is denied to this object.


What is the reason of this error (while creating instance of the access)?.
Is there any problem with my IIS server setting ?If there, how to solve it?

Please help me?
Thanking in advance.

From Vinod

Back to Top
WebWiz-Bruce View Drop Down
Admin Group
Admin Group
Avatar
Web Wiz Developer

Joined: 03 September 2001
Location: Bournemouth
Status: Offline
Points: 9844
Post Options Post Options   Thanks (0) Thanks(0)   Quote WebWiz-Bruce Quote  Post ReplyReply Direct Link To This Post Posted: 19 July 2004 at 3:26am
The error means that the component you are trying to use is not installed on the server.
Back to Top
Mart View Drop Down
Senior Member
Senior Member
Avatar

Joined: 30 November 2002
Status: Offline
Points: 2304
Post Options Post Options   Thanks (0) Thanks(0)   Quote Mart Quote  Post ReplyReply Direct Link To This Post Posted: 19 July 2004 at 4:50am
I thought that meant your account doesn't have permission to use that component.
Back to Top
WebWiz-Bruce View Drop Down
Admin Group
Admin Group
Avatar
Web Wiz Developer

Joined: 03 September 2001
Location: Bournemouth
Status: Offline
Points: 9844
Post Options Post Options   Thanks (0) Thanks(0)   Quote WebWiz-Bruce Quote  Post ReplyReply Direct Link To This Post Posted: 19 July 2004 at 4:53am
Sorry your right, I just read the bit Server.CreateObject failed and as this was posted in the wrong forum, the Web Wiz Forums support forum, I'm use to seeing the failed message when the component is not installed on the web server when relating to support for Web Wiz Forums.
Back to Top
Mart View Drop Down
Senior Member
Senior Member
Avatar

Joined: 30 November 2002
Status: Offline
Points: 2304
Post Options Post Options   Thanks (0) Thanks(0)   Quote Mart Quote  Post ReplyReply Direct Link To This Post Posted: 19 July 2004 at 4:59am
To counter it make sure your account has administrative privileges, since you are executing an external program you need to have an administrative account on the server.
Back to Top
michael View Drop Down
Senior Member
Senior Member
Avatar

Joined: 08 April 2002
Location: United States
Status: Offline
Points: 4670
Post Options Post Options   Thanks (0) Thanks(0)   Quote michael Quote  Post ReplyReply Direct Link To This Post Posted: 19 July 2004 at 9:02am
Now that would be scary if you need admin privileges to execute an external program. All you need is explicit permissions to that  component. Access.Application is usually in the Office folder and the iusr account does not have permissions to there, or it's registry keys.
Back to Top
Mart View Drop Down
Senior Member
Senior Member
Avatar

Joined: 30 November 2002
Status: Offline
Points: 2304
Post Options Post Options   Thanks (0) Thanks(0)   Quote Mart Quote  Post ReplyReply Direct Link To This Post Posted: 19 July 2004 at 10:33am
Oh, I thought you needed admin rights because in .NET Office interop only works if you are logged in as an admin
Back to Top
vinodkalpaka View Drop Down
Newbie
Newbie


Joined: 19 July 2004
Location: India
Status: Offline
Points: 3
Post Options Post Options   Thanks (0) Thanks(0)   Quote vinodkalpaka Quote  Post ReplyReply Direct Link To This Post Posted: 20 July 2004 at 2:35am
dear,

Thanks for you suggestions.That error is not appearing now ,but appering another error,

error '800a1eba'

if i trap the error with asp code

it shows the message

Microsoft Access can't open the database because it is missing, or opened exclusively by another user.

but this database is not opened elsewhere.
Is this the correct code for dynamically creating snapshots from asp.
If no ,please give help me.

Thank you

from,
Vinod

Back to Top
 Post Reply Post Reply

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.08
Copyright ©2001-2026 Web Wiz Ltd.


Become a Fan on Facebook Follow us on X Connect with us on LinkedIn Web Wiz Blogs
About Web Wiz | Contact Web Wiz | Terms & Conditions | Cookies | Privacy Notice

Web Wiz is the trading name of Web Wiz Ltd. Company registration No. 05977755. Registered in England and Wales.
Registered office: Web Wiz Ltd, Unit 18, The Glenmore Centre, Fancy Road, Poole, Dorset, BH12 4FB, UK.

Prices exclude VAT at 20% unless otherwise stated. VAT No. GB988999105 - $, € prices shown as a guideline only.

Copyright ©2001-2026 Web Wiz Ltd. All rights reserved.