Where's Excel.dll in Office 2016 / 365
I'm working on modelling software in which users are able to write their own VBA macros via the VBA ide. I'm working on a bug that requires me to load up a model created by a customer. The model won't load on my machine but does on his so this is getting in the way of me looking at the actual bug they've reported. The load fails on this line of code:-
VBProject.References.AddFromGuid(guid, majorVersion, minorVersion);
with the following error:-
System.Runtime.InteropServices.COMException: 'Object library not registered'
I can find the guid in the registry and it appears to apply excel (although it appears to reference the exe, not a dll as I'd have expected).
The only difference I can find between the model on his machine and mine is that his VBA project has a reference to the Microsoft Excel 16 Object Library and mine doesn't, which would seem to fit with my findings in the registry. However, I can't seem to add it. I can see the path on his machine:-
C:\Program Files (X64)\Microsoft Office\Root\Office16\EXCEL
That path doesn't exist for me.
My first assumption was that I don't have Office 16 installed. I have office 365 installed. But reading around the net I believe that Office16 is Office 365 (16 is the package, 365 is basically the license under which that package is purchased). I've done a search of the machine for any Excel.dll but not finding it.
Any thoughts?
Re: Where's Excel.dll in Office 2016 / 365
Shouldn't it be a reference to Excel.EXE, it's after all an ActiveX EXE
Re: Where's Excel.dll in Office 2016 / 365
Yes. Yes it should. It's been that long since I moved over to .Net that I forgot you could add a reference to an exe.
I could give you a hug right now.
Re: Where's Excel.dll in Office 2016 / 365
Re: Where's Excel.dll in Office 2016 / 365
I had the same problem and staff couldn't help me, it was just version incompatibility
Re: Where's Excel.dll in Office 2016 / 365
This could be related to an incorrect installation or missing components. I have a lifetime Office license that's always up to date and has customer support for such issues.