Your manifest is missing essential entries, like <comClass>
. Which is why you see Windows continue hunting for another manifest to find what it needs. The workaround you found isn't that great, it puts the manifest entries in the wrong file. It should go in the manifest of the EXE.
The Smart Way to do this is to just let the build system take care of this. Register the .ocx and just set the Isolated
property of the reference to True. That will get the build system to read the required manifest entries from the registry and merge them into the application manifest.
If you don't want to leave the .ocx registered for some reason then do this just once. Find the .manifest file back in the build directory. Open it with a text editor and copy/paste the entries into your app manifest. Do beware that this can invoke DLL Hell, if you update the COM server then your manifest will be outdated. Always hard to troubleshoot since this will happen a year or two from now and probably to a programmer that doesn't have a clue what you did.