Ask a Question related to ASP.NET Web Services, Design and Development.
-
Nalina Vemparala via .NET 247 #1
Web service in .net not able to create Excel com object
(Type your message here)
Hi!
I created a web service in .net where in the web method makes call to a function in which I am creating an excel object using
Dim objXl As New Microsoft.Office.Interop.Excel.Application()
objXl.Workbooks.Open("C:\C\Test.xls")
objXl.Visible = True
However, I am getting the error Access denied, Cannot create Activex component.
The same code works in a ASP page and also in .net windows application.
But if I access this code through web service I get the error Access denied, Cannot create Activex component.
I checked the permissions etc for this web service project
Could anyone please help me please.
--------------------------------
From: Nalina Vemparala
-----------------------
Posted by a user from .NET 247 ([url]http://www.dotnet247.com/[/url])
<Id>K4FlI6gD5EyFFDUQg55O5g==</Id>
Nalina Vemparala via .NET 247 Guest
-
Cannot Create New Instance of COM+ Object After You Repeatedly Restart the COM+ Object
I've checked that the server I'm working on has win2k sp4 which had a fix from microsoft for this problem. However, it seems that I still have... -
Excel create object error
Hello! I have an ASP page that creates an Excel object: set lobjXLSApplication = CreateObject("Excel.Application") This used to run fine on my... -
COM Object Excel
Hi, I was using a Coldfusion 4.5 server on a windows NT platform on which I was exporting datas in a Excel 97 using COM object. I've migrated all... -
Create Excel worksheet by using web service
I want to create a excel file by using web serivce. Can web service do that? and how? Thanks. -
Excel object in ASP
I am trying to use an excel spreedsheet on an asp.net page. The follow code works (with output mod.) in a .net console application. When I try to... -
Joe H #2
Re: Web service in .net not able to create Excel com object
the asp.net process runs under a special user. that user will not by
default have rights to resources outside the scope of the web service.
imagine what would happen if a web service could call ANY code on your
server. there are many ways to approach this depending on your environment
and what it is that you are trying to achieve. but at the most basic level,
you need to give the aspnet user the rights to launch excel.
"Nalina Vemparala via .NET 247" <anonymous@dotnet247.com> wrote in message
news:#tvUZyMJEHA.1192@TK2MSFTNGP11.phx.gbl...function in which I am creating an excel object using> (Type your message here)
> Hi!
> I created a web service in .net where in the web method makes call to acomponent.> Dim objXl As New Microsoft.Office.Interop.Excel.Application()
> objXl.Workbooks.Open("C:\C\Test.xls")
> objXl.Visible = True
> However, I am getting the error Access denied, Cannot create Activexdenied, Cannot create Activex component.> The same code works in a ASP page and also in .net windows application.
> But if I access this code through web service I get the error Access> I checked the permissions etc for this web service project
> Could anyone please help me please.
> --------------------------------
> From: Nalina Vemparala
>
> -----------------------
> Posted by a user from .NET 247 ([url]http://www.dotnet247.com/[/url])
>
> <Id>K4FlI6gD5EyFFDUQg55O5g==</Id>
Joe H Guest
-
Dino Chiesa [Microsoft] #3
Re: Web service in .net not able to create Excel com object
Also, let's repeat that MS Office components were not designed to be used
from within server-based apps such as ASP.NET webservices (or ASP Pages for
that matter).
[url]http://support.microsoft.com/default.aspx?scid=kb;EN-US;257757[/url]
--
Dino Chiesa
Microsoft Developer Division
d i n o c h @ ElideThis . m i c r o s o f t . c o m
"Joe H" <jharri@hotmail.com> wrote in message
news:%23HNzjCVJEHA.2380@TK2MSFTNGP09.phx.gbl...environment> the asp.net process runs under a special user. that user will not by
> default have rights to resources outside the scope of the web service.
> imagine what would happen if a web service could call ANY code on your
> server. there are many ways to approach this depending on yourlevel,> and what it is that you are trying to achieve. but at the most basic> you need to give the aspnet user the rights to launch excel.
>
> "Nalina Vemparala via .NET 247" <anonymous@dotnet247.com> wrote in message
> news:#tvUZyMJEHA.1192@TK2MSFTNGP11.phx.gbl...> function in which I am creating an excel object using> > (Type your message here)
> > Hi!
> > I created a web service in .net where in the web method makes call to a> component.> > Dim objXl As New Microsoft.Office.Interop.Excel.Application()
> > objXl.Workbooks.Open("C:\C\Test.xls")
> > objXl.Visible = True
> > However, I am getting the error Access denied, Cannot create Activex> denied, Cannot create Activex component.> > The same code works in a ASP page and also in .net windows application.
> > But if I access this code through web service I get the error Access>> > I checked the permissions etc for this web service project
> > Could anyone please help me please.
> > --------------------------------
> > From: Nalina Vemparala
> >
> > -----------------------
> > Posted by a user from .NET 247 ([url]http://www.dotnet247.com/[/url])
> >
> > <Id>K4FlI6gD5EyFFDUQg55O5g==</Id>
>
Dino Chiesa [Microsoft] Guest
-
freekamel #4
Re: Web service in .net not able to create Excel com object
Hi,
use "dcomcnfg.exe" to config your policy for Dcom
select the "Default Security pane", insert user everyOne and give it "special Access" right into the tre
option allowed
Restart Your system and good luck
N.B.: Word works very well but Excel not finds the default printer specified i
system registrykeys "[HKEY_USERS\.DEFAULT\Software\Microsoft\Windows NT\CurrentVersion\"
devices, printerports and windows like Microsoft suggests
freekamel Guest



Reply With Quote

