Excel Automation in C#....getting "Access Denied" error

J

Jon Rista

Hello. I'm trying to automate Excel in a C# Windows Service. This windows
service has to be able to access files on network shares, so it uses a
domain account on a WinNT 4.0 domain server, rather than the Local Service
or Network Service, or System account. I'm running into a problem, though,
with trying to instantiate Excel. When I execute the following:

using Excel = Microsoft.Office.Interop.Excel;
using Microsoft.Office.Core;

// .....

// Instantiate excel object
Excel.Application myExcel = new Excel.Application();

I recieve an excetion with the message "Access Denied.". I'm assuming this
is due to the fact that I am using a network domain account, rather than a
local system account. I do not, however, know how to solve the problem, or
where to look to find help solving it. Any ideas?
 

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

Top