Excel XP error when running on IIS

  • Thread starter Robert Magnusson
  • Start date
R

Robert Magnusson

I've written a client-side DLL in Visual Basic v6.0 that
formats a number of PivotTables and presents the report to
the client through Excel.

This works fine for Excel 97, 2000 and XP.

I am trying to take this same DLL and have it run on the
IIS server, save the resulting Workbook as HTML and return
the http address to the browser so that it can then open
the report in HTML. With Office XP loaded on the IIS
Server, when the following line of code is run, a 1004 -
Application-defined or object-defined error is thrown.

Set pt = ws.PivotTables.Add(pc, o, sName)

where pc is a successfully created PivotCache object
(though dimensioned as Object in the code),
o is a cell range (basically Cells(3, 1) although
again dimensioned as Object in the code),
ws is a worksheet

This code works fine if the DLL runs on the client-side so
I'm trying to work out what changes when run under IIS.

Can anyone help?

Regards,

Rob
 
J

Joel Alley [MSFT]

Excel is not designed to run in a server side environment. There is no way
to configure Excel so that it will run reliably under IIS. Please see the
following Knowledge Base article for more information.

257757 INFO: Considerations for Server-Side Automation of Office
http://support.microsoft.com/?id=257757

Thanks,
Joel Alley,MCSD
 

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