I have a c++ solution that generates an xll addin that works fine. OS is Windows 7 Enterprise 6.1 Build 7601 Service Pack1, compiler is Visual C++ 2010 Express and Excel is 2007 32bit. Notice that the sln uses boost libs. Now I have to update to Windows 10 version 1903 and Excel 365 with compiler Visual Studio 2019. After some painful times I managed to recompile the solution with no errors. When loading the addin from Excel I get the same behaviour as in C++ Excel Add-in loading error: XLL file is loaded by Excel as text file. However, I double checked that:
- sln is built in 32bit and Excel version is 32 bit
- all boost libs have been build in 32 bit
- I built under MDd and boost libs have been also built under MDd.
When using dependencies.exe to figure out if any dll is missing, I get "C:\Windows\SysWOW64\OLEAUT32.dll module has missing imports". Expanding the point I see that api-ms-win-core-wow64-l1-1-1.dll is missing. I also tried to open the xll on my old laptop with Windows7 and Excel 2007, and I get the same error, so I guess that it cannot really relate to dlls missing on new laptop and present on old one. I finally added to my PATH the variables SystemRoot%\system32%, %SystemRoot%, C:\Windows\System32 where the dlls are located, but still getting the same error.
Do you have any idea about possibile reasons for this behaviour?
Thanks for helping
EDIT: When compiling in release, Dependencies does not show any missing dll. However, also the Release xll shows the same error when loaded in Excel