Click here to Skip to main content
15,886,825 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
When trying to read excel file from the ASP.Net web application getting following error -

Retrieving the COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 80080005 Server execution failed (Exception from HRESULT: 0x80080005 (CO_E_SERVER_EXEC_FAILURE)).
Posted

You're trying to do Interop with Excel. This is NOT supported in a web application as Excel doesn't really support multiple requests at the same time.

Read this[^] to find out why.
 
Share this answer
 
v2
To get that code working you'll need Excel installed and launchable from your web code. This is hard to get working, and not supported by Microsoft and won't really work anyway. You can try something like the Open XML SDK to read Excel documents, or the Excel ODBC driver, or Aspose etc.

http://typecastexception.com/post/2013/09/25/C-Query-Excel-and-CSV-Files-Using-LinqToExcel.aspx[^]
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900