当我在IIS中托pipe我的DotNet应用程序时Excel文件不打开

我有我的DotNet应用程序,我打开Excel文件通过从数据库获取pathbutton单击,它工作正常,但是当我在IIS中托pipe我的应用程序,然后我得到以下exception –

System.Runtime.InteropServices.COMException (0x800A03EC): Exception from HRESULT: 0x800A03EC at Excel.Workbooks.Open(String Filename, Object UpdateLinks, Object ReadOnly, Object Format, Object Password, Object WriteResPassword, Object IgnoreReadOnlyRecommended, Object Origin, Object Delimiter, Object Editable, Object Notify, Object Converter, Object AddToMru, Object Local, Object CorruptLoad) 

请帮忙…

我通常会发现这些是与IIS中的网站相关的用户的权限问题。 确保IIS用户有权访问该文件。

顺便说一下,我可能会考虑使用不需要使用Excel自动化的第三方DLL。 如果您不需要XLSX支持,我已经与NPOI取得了很好的成功。 只是一个build议。

祝你好运。