I will make it very simple, as it can get very confused very quickly. I have a COM-dll (made in VB6) that I would like to use in my C # application. Below are the steps I took and the results.
- COM DLL created through Visual Basic 6
- Added COM DLL to .Net application.
- Get the file "interop.dllName.dll" generated by .NET in x86 / Debug
- Added the interop file as a reference assembly to my exe file with CodeDom code.
- The .exe file generated by CodeDom worked fine on my machine when the .exe file was in the same directory as the interop.dllname.dll file
- The generated CodeDom.exe file did not work at all on the deployed machine, although the interop.dllname.dll file existed in the same directory as the .exe file.
Note:
The source COM .dll file is not registered on the deployed computer because the deployed computer does not recognize the COM-DLL as a valid dll file.
COM.dll was created in x86, and the deployed machine runs in x64 (does it matter)?
What is my goal: I would like to be able to generate the .exe file with the CodeDom code without depending on the interop.dllname.dll file. Is there a way to store these dll files in memory? In addition, I do not want my user to have to register the DLL files before they can use the generated .exe codedom file. Is there any way to do this?
I appreciate any help on this.
Thank you for your time,
Evan
user725913
source share