Office Interope Needs IIS restart-Windows Server2008R2-IIS7

0

I have an application hosted at Windows server 2008R2 with IIS7 with MS Excel2013 32bit. This application uses Excel application to convert excel sheets to webpages. It works fine until user keeps using it. but if no user uses application for an hour or two and use it again the application throws error while opening excel application And if I restart IIS it starts working fine. here is the exception I get

 System.Runtime.InteropServices.COMException (0x8000401A)

I am not being able to figure out the reason behind it.

windows-server-2008
iis-7
microsoft-excel
asked on Server Fault Apr 21, 2015 by Addy • edited Apr 21, 2015 by Addy

1 Answer

0

This is a common issue with Web applications when not initialized after receiving of the first request started. Try the following

  1. Create a scheduled task to start the application if it is not already running. such as through powershell

    $appPath = "c:\mypath"

    & $appPath "arg1"

  2. Install Always Running assuming you have IIS 7.5

answered on Server Fault Apr 29, 2015 by lloyd • edited Apr 29, 2015 by lloyd

User contributions licensed under CC BY-SA 3.0