I am trying to build a VB.NET project in the Visual Studio 2019, which has a reference to the Microsoft HTML Object Library. The referenced file is located in "C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\Common7\IDE\PublicAssemblies\Microsoft.mshtml.dll".
While trying to build the project I am getting an error: "Cannot find wrapper assembly for type library "MSHTML". Verify that (1) the COM component is registered correctly and (2) your target platform is the same as the bitness of the COM component. For example, if the COM component is 32-bit, your target platform must not be 64-bit."
I am using Windows 7 (x64), the project is targeted for "Any CPU". I tried to run the "regasm Microsoft.mshtml.dll" command from the Developer Command Prompt, the command completed successfully, but it did not help.
How can I fix this?
While trying to build the project I am getting an error: "Cannot find wrapper assembly for type library "MSHTML". Verify that (1) the COM component is registered correctly and (2) your target platform is the same as the bitness of the COM component. For example, if the COM component is 32-bit, your target platform must not be 64-bit."
I am using Windows 7 (x64), the project is targeted for "Any CPU". I tried to run the "regasm Microsoft.mshtml.dll" command from the Developer Command Prompt, the command completed successfully, but it did not help.
How can I fix this?