Click here to Skip to main content
15,878,814 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I have a C# COM assembly that uses a C++ rapper to communicate with another program. Every thing works just fine on the machine that I build the C#/C++ assembly on but when I try to use assembly on another machine I keep getting the error message that the .dll cannot be found.

Does anyone have any idea what is going on here?
Posted
Updated 21-Nov-11 12:10pm
v2
Comments
Arun Kumar K S 21-Nov-11 21:50pm    
Register your dll in your client machine to get correct path

First verify the the DLL is actually installed at the proper location. Then ensure that all dependencies are also installed (for example, the appropriate version of the C++ run-time library)
 
Share this answer
 
Comments
Sergey Alexandrovich Kryukov 21-Nov-11 21:33pm    
I voted 5 for this advice and credited it in my solution where I just add an important item to it: using Dependency Walker, please see.
--SA
In addition to the correct advice by Philippe Mori: you really need to make sure all the executable your application depends on are available and placed in proper location. To figure out these dependencies, use Microsoft Dependency Walker:
http://en.wikipedia.org/wiki/Dependency_Walker[^],
http://msdn.microsoft.com/en-us/magazine/bb985842.aspx[^],
http://www.dependencywalker.com/[^] (here you can download it).

—SA
 
Share this answer
 
Comments
d.allen101 21-Nov-11 22:34pm    
THANKS! that was it. I didn't have all the dependencies.
Sergey Alexandrovich Kryukov 22-Nov-11 0:16am    
Great! If so, will you please accept this answer formally (green button); you can accept more then one -- thanks.
--SA

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900