473,378 Members | 1,209 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,378 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 2013
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...
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...
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...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

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.