Cannot create Excel Object via executable called from ASP.Net

K

Keith McDonald

We have executable program that is used to create and send emails to
users. Working on getting it able to be called from a web page we're
having some problems. First of all if debugging the website from local
it returns the common JIT debugger failure, access denied after the
Process.Start() call. Access denied for machine\ASPNET. Haven't been
able to correct even by adding the user to Administrators but can get
around by changing machine.config-processmodel-username to system.

Once past that we can see where it is erroring with
System.Runtime.InteropServices.COMException. Server execution failed.

on this line
Dim oExcel As New Microsoft.Office.Interop.Excel.Application

I assume this is also a permissions issue but running via system gives
this error so not sure what is wrong.

Any ideas?

Thanks.
 
W

Winista

1. Either use impersonation for your asp.net app or give the right to ASPNET
to execute Excel executable. By changing machine.config you have forced
every single ASP.Net app on your machine to run under that user context.

2. Try setting ASPCOMPAT attribute on your page. You may be runing into
threadong model issue.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,582
Members
45,057
Latest member
KetoBeezACVGummies

Latest Threads

Top