Click here to Skip to main content
15,883,744 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hello All,

I'm working with C# console application and importing external dll(kmbds.dll) into application and using one function from that dll but after calling that function it's throwing following error:

"Unable to load DLL 'kmbds.dll': This application has failed to start because the application configuration is incorrect. Reinstalling the application may fix this problem. (Exception from HRESULT: 0x800736B1)"

I'm not able to add it from project references.So add it with following lines in a code:

[System.Runtime.InteropServices.DllImport("kmbds.dll")]

private static extern int GetAddress(string szPath, ref IntPtr a);


Thanks
Posted
Comments
Abdullatif M. Abu Al Rub 6-Apr-13 4:12am    
my friend i didn't see that error before,,, but here is an example of importing dll library, check if you've missed something. http://www.adp-gmbh.ch/csharp/call_dll.html
regards
Babak Mahmoudi 7-Apr-13 0:56am    
It seems that "kmbds.dll" is using some other dll(s) that are not accessible. Try to copy any other dll that may be used by kmbds, to your application folder. You may use "Depends.exe" to check kmbds.dll dependencies on other dlls.

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