473,320 Members | 2,027 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

Access Is Denied

Ed
I have searched the archives and found several entries that address the problem I'm having, however, the solutions fall short of explaining exactly what to do

Like many others, when I attempt to access an Excel file via an ASP.NET page, I get an access is denied error on the line "dim XSL as new Excel.application"

some solutions tell me to change my authentication in web.config file - I don't know what to chang
some solutions tell me to enter component services and change the default security settings on my dcom - which dcom, there's only about 50 of the things. I did the obvious, changed it on the excel application - didn't work

these solutions addressed this application and a given file. this is being developed on a development machine with IIS installed and running as the test platform. assuming I get it to work here, what changes on the IIS network server and the file server when I move the file and the apps

if anyone would be gracious enuf to take the time and give the step by step instructions as to what to change and where, I would be most appreciative. sorry for the sarcastic overtones, its been a long day

Thanx
Ed.
Jul 21 '05 #1
2 1762
See comment inilne.

"Ed" <an*******@discussions.microsoft.com> wrote in message
news:78**********************************@microsof t.com...
I have searched the archives and found several entries that address the problem I'm having, however, the solutions fall short of explaining exactly
what to do.
Like many others, when I attempt to access an Excel file via an ASP.NET page, I get an access is denied error on the line "dim XSL as new
Excel.application".

The user account used for the web application (by default, it is ASPNET)
usually does not have permission to run programs on the server outside the
web app, unless you/server administrator authorize the web app user account
to do so.

some solutions tell me to change my authentication in web.config file - I don't know what to change

Authentication does not make things different regarding permission,
authorization does. They are different things. You need to give the user
account of your web app (ASPNET, or other if you impersonate the account),
permisstion t execute "EXCEL.EXE" (located in C:\Program files\Microsoft
Office\Office[office10][office11]).

Theoretically, you can run office desktop apps on web server, but it is
usually a bad design. Apps in office are never designed to run in an
unattended web server, especially if the server is open to the Internet. You
may be able to run it fine in a small network, like your office LAN, with
little chances of many users accessing Excel on the server concurrently, on
a publicly accessible web server, with unkonown concurrent users' access,
you may end up with so many Excel apps launched and not responding due to
unexpected warning messagebox. Who is going to the server physically dismiss
that?
some solutions tell me to enter component services and change the default security settings on my dcom - which dcom, there's only about 50 of the
things. I did the obvious, changed it on the excel application - didn't
work.
these solutions addressed this application and a given file. this is being developed on a development machine with IIS installed and running as the
test platform. assuming I get it to work here, what changes on the IIS
network server and the file server when I move the file and the apps?
if anyone would be gracious enuf to take the time and give the step by step instructions as to what to change and where, I would be most
appreciative. sorry for the sarcastic overtones, its been a long day.
Thanx.
Ed.

Jul 21 '05 #2
If your purpose is to read (or event update) data in *.xls file, you do not
have to open it in Excel on the web server. Yo can use OleDb namespce to
handle data in *.xls file as a database. This way you can simply put the
*.xls file in your web app's directory/subdirectory, so the web app user
account can access it without extra permission problem. To use OleDb to
access data in *.xls file, someone just asked a similar question and William
Ryan gave a good reply, here I copy the reply here for your convenience
(follow the link Ryan gives):
William Ryan wrote:
If you need to manipulate the data once you open it and do anything with the
worksheets, than you are probably going to have to use COM. However, if you
just need to open it up and read in data and possibly write it back, then
check this out.. http://www.knowdotnet.com/articles/exceldatasource.html

"João Santa Bárbara" <jo****@i24portugal.com> wrote in message
news:#2**************@tk2msftngp13.phx.gbl...
Hi all
i need to open a Excel File Without using the com Objects, how can i do this ???

i have see that msoffice 2003 install in the windows\Assmbly Directory an
assembly, but i tried to browse it via reference, but dotnet 2003 doens´t
accept ? how can i solve this ???

thsk
JSB


"Ed" <an*******@discussions.microsoft.com> wrote in message
news:58**********************************@microsof t.com... Thanx for the information and tip, however, when I gave permissions to execute to ASPNET and then reran the form, I got the same error - Access
denied. I understand that using Excel in a web app is a bad idea, however,
we have users here that put a lot of data into an Excel spreadsheet(s -
100s) and now need to get those data to the DB. In my attempt to learn
ASP.NET I thought it would be a good exercise to move this data using
ASP.NET. I'm not under any time constraint (yet) and I would be the only one
using the app - so, what the hell - give it a try.
In so far as the access denied error, I have no idea what to do next - can find any documentation (on-line books) about it.
Ed.

Jul 21 '05 #3

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

Similar topics

2
by: calfdog | last post by:
Hello, Does anyone know a workaround for calling fireEvent. With the latest from Microsoft OS XP2 and Hot fixes to IE it now gives an "access denied" error in Python when called. Here is what...
0
by: Steve | last post by:
Hi, Yesterday I signed up for another dedicated linux server with the hosting company I use and I am having problems getting MySQL 4.1.3 working on it. I've tried just about everything I can...
9
by: | last post by:
Hi All, I have allready tried to ask a similar question , but got no answer until now. In the meantime, I found, that I cannot understand some thread-settings for the Main() function . If I use...
0
by: ASP.Confused | last post by:
The old message looked a little stale, so I am re-posting it here. Anybody have any ideas of what I could do?!? The previous responses to this question are below. If you want to look at the...
16
by: Brad | last post by:
After compiling my asp.net project I'm receiving a "BC31011 - Access is denied" error when attempting to run or debug. The only thing that seems to resolve problem is IISReset. After a reset my...
12
by: Ron Weldy | last post by:
I have a test server runinng 2003/IIS 6 with a mixture of asp and asp.net files. On my workstation I have a share set up to the folder where the web files reside. I am just doing quick and dirty...
3
by: Shailesh Humbad | last post by:
I figured out what was causing the "Access is Denied" error when calling functions from referenced DLLs in my service. I've tried to be very detailed, so bear with me. It turns out that...
3
by: David Thielen | last post by:
Hi; I created a virtual directory in IIS 6.0 and my asp.net app runs fine. But when it tries to write a file I get: Access to the path is denied. - C:\Inetpub\wwwroot\RunReportASP\images ...
8
by: Jeremy Ames | last post by:
I am trying to move an application from my system to a new test system. I really should have tried an easier program first, but I didn't really have a chance. My application was originally written in...
0
by: Andy | last post by:
Thanks Peter, I thought I'd give an update on this problem. My application had 2 assemblies that contained classed for the Data access and business logic layer. It was on one of them that I was...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

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.