Click here to Skip to main content
15,881,898 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi experts

I know that i can use DllImport for unmanaged dlls

C#
[DllImport("SomeFile.dll", EntryPoint="SomeFunction", SetLastError=true)]


But I got a DLL file which I don't know it's functions names.

Is there any way to find the functions of an unmanaged DLL file? like iterating or something? and how?

What I have tried:

I've been googling the issue and I haven't found anything useful so far.
Posted
Updated 22-Jun-16 1:10am
v2

1 solution

You can find the names by using one of the many tools available from the internet such as Dependency Walker (depends.exe) Home Page[^]. However, you will most likely find that you need more information in order to use these functions.
 
Share this answer
 
Comments
Sergey Alexandrovich Kryukov 22-Jun-16 9:50am    
5ed. Unknown signatures of those functions will still present a problem; name mangling, if it was used, can give some help, but not in all cases. So, you are right about "you need more information".
—SA
Richard MacCutchan 22-Jun-16 10:01am    
Isn't that what I said in my reply?
Sergey Alexandrovich Kryukov 22-Jun-16 10:08am    
Let me see... Almost. You did not say what is that "more information", but I agree if you say that it's pretty obvious. Was my word "but" wrong? Well, I'll remove it.
—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