![microsoft office interop excel dll version 12.0.0.0 microsoft office interop excel dll version 12.0.0.0](https://www.engram9.info/office-2007-vba-2/images/3633_226_323.jpg)
Solutions that were attempted proved only to be a temporary fix, with the problem reverting back again, often overnight.Ĭould not load file or assembly .dll or one of its dependencies. NET application would fail with errors of “Access is denied” when launching our integrating application. The story, on a newly deployed set of PCs, a big issue arose where the Microsoft Office Interop for our. This is the solution to a perplexing issue around Office automation, that many people do not seem to be finding a solution for on forums. NET Problem, Could not load file or assembly … or one of its dependencies. Public partial class _Default : .24 January 2020 Tim-Wappat.
![microsoft office interop excel dll version 12.0.0.0 microsoft office interop excel dll version 12.0.0.0](https://catchyellow325.weebly.com/uploads/1/2/6/8/126899622/354685210.png)
This is because unlike the developer’s station, the COM object isn’t present on the server (Office cannot be installed on the servers – licensing, security, and performance issues prevent this). Upon uploading the interop to the bin directory, the application will at least then compile, but attempting to work with the interop will result in the second error. The application itself isn’t concerned with the COM object, only the interop assembly. In this case, we are interested in programmatically accessing the functionality of the Excel COM object. NET (the CLR specifically) to leverage unmanaged libraries. If it runs on the developer’s machine, why doesn’t it run on the server?įirst, some background. However this would lead to another error, similar to: Retrieving the COM class factory for component with CLSID įailed due to the following error: 80040154. Naturally, they would then assume they needed to upload the .dll file to the bin directory. The system cannot find the file specified. PublicKeyToken=71e9bce111e9429c' or one of its dependencies. While this would indeed work on the developer’s machine, once uploaded to the server, an error such as the following would be thrown: Could not load file or assembly ', Version=12.0.0.0, Culture=neutral, Worksheet myWorkSheet = (Worksheet)myWorkBook.Worksheets Workbook myWorkBook = (XlWBATemplate.xlWBATWorksheet) Protected void Button1_Click(object sender, EventArgs e) Let’s start with the initial creation of the application on a developer’s box with Microsoft Office installed on it. The scenario I outline below is rather common. Populating cells and doing other tasks, while easy enough, would detract from the focus of this post. As OWC is a thing of the past, I’m going to concentrate on interoperability issues and a solution to the problem (more on that later).įor the purposes of these examples, all we are going to do is create a document. We have noticed an increase in interest from our customers in incorporating Microsoft Excel automation tasks into their ASP.NET applications.