Any Tool that can explore DLL

  • Thread starter Thread starter John
  • Start date Start date
J

John

Hi,

In C#, we can use p/Invoke by using [DllImport()] to define extern function
to call C/C++ DLL. Is there any tool/wizard that we can use to explore the
DLL (without header file) and generate the [DllImport()] extern function
automatically?

Sometimes when I could not delete a file because it's used by another
process - is there any tool that can display which process is using that
file?

Thanks!

John
 
John said:
Hi,

In C#, we can use p/Invoke by using [DllImport()] to define extern
function
to call C/C++ DLL. Is there any tool/wizard that we can use to explore the
DLL (without header file) and generate the [DllImport()] extern function
automatically?

I don't know of one. Without some sort of symbols or .h files, I doubt a
tool could figure out what parameters a function takes anyway. Dll's don't
generally carry around metadata about parameters, etc(although, if memory
serves, its possible to determine arguments from a C++ mangled function).
Sometimes when I could not delete a file because it's used by another
process - is there any tool that can display which process is using that
file?

Process Explorer from systernals will help you here:
http://www.sysinternals.com/ntw2k/freeware/procexp.shtml
 
Thank Daniel!

The Process Explorer is really good tool!

I found out that Microsoft had a webcheck.dll running - I was wondering if
that process actually watch which website we are visiting? :<

OK, Do we have tool to generate the [DllImport()] extern function
automatically if we do have header file?

Thanks again!

John

Daniel O'Connell said:
John said:
Hi,

In C#, we can use p/Invoke by using [DllImport()] to define extern
function
to call C/C++ DLL. Is there any tool/wizard that we can use to explore the
DLL (without header file) and generate the [DllImport()] extern function
automatically?

I don't know of one. Without some sort of symbols or .h files, I doubt a
tool could figure out what parameters a function takes anyway. Dll's don't
generally carry around metadata about parameters, etc(although, if memory
serves, its possible to determine arguments from a C++ mangled function).
Sometimes when I could not delete a file because it's used by another
process - is there any tool that can display which process is using that
file?

Process Explorer from systernals will help you here:
http://www.sysinternals.com/ntw2k/freeware/procexp.shtml
Thanks!

John
 
I found out that Microsoft had a webcheck.dll running - I was wondering if
that process actually watch which website we are visiting? :<

It is part of Internet Explorer. Of course it knows which web site you're
visiting...
 
Hi John,

Thank you for posting in the community!

Actually, microsoft did not provide a tool to do this. After searching in
internet, I found that there is tool "P/Invoke Wizard" may meet your need.

It is a tool developed by The Paul Yao Company, you can get the tool at:
http://www.paulyao.com

For more information, please refer to:
http://www.paulyao.com/cfbook/Ch04_Preview_cs.pdf

Addtionally, it seems that this tool is not free.

==========================================
Thank you for your patience and cooperation. If you have any questions or
concerns, please feel free to post it in the group. I am standing by to be
of assistance.

Best regards,
Jeffrey Tan
Microsoft Online Partner Support
Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.

This reply contains a reference to a third-party World Wide Web site.
Microsoft is providing this information as a convenience to you. Microsoft
does not control these sites and has not tested any software or information
found on these sites; therefore, Microsoft cannot make any representations
regarding the quality, safety, or suitability of any software or
information found there. There are inherent dangers in the use of any
software found on the Internet, and Microsoft autions you to make sure that
you completely understand the risk before retrieving any software from the
Internet.
 
Hi John,

Does the community's reply make sense to you?

If you still have any concern, please feel free to feedback, we will help
you.

Best regards,
Jeffrey Tan
Microsoft Online Partner Support
Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.
 
Back
Top