-1

When I open some .NET assembly using ILSpy - I can see the table method ( attached screenshot )

I need to find the method signature ( like on the screenshot ) from C++ code. I found that using the Interface ICorProfilerInfo8 and i can get information about the assembly but still I didn't find any way to get the method signature like the ilSpy do it ( I want to have the signature exactly like in the screenshot )

*to see the signature like i did - you need to move the mouse over the signature

enter image description here

enter image description here

Yanshof
  • 9,297
  • 18
  • 86
  • 178
  • Are you looking to find the C++ function signature? You can use depends in sys internals from Microsoft. Then you can call the function via a PInvoke from C# code or from C++ use a LoadLibrary and then a LoadProcess – Marco Beninca May 11 '22 at 07:28
  • @MarcoBeninca - yes, i need to know the signature on runtime. i don't have any possible to use anything else beside this interface and i don't have any option to use C# code .. only C++ on my case ( no possible to user PInvoke). I sure there is a way but i still did't find it. so i asking for any help :) – Yanshof May 11 '22 at 07:37
  • https://docs.microsoft.com/en-us/dotnet/framework/unmanaged-api/metadata/imetadataimport-interface – Hans Passant May 11 '22 at 09:33
  • @Yanshof use the link [depends](https://dependencywalker.com/) to download the tool then load your dll. The tool will give you all the depends and the exported functions, As I told you to call a C++ function first use `LoadLibrary` to load the library then `LoadProcess` to load the function which return a function pointer which can let you to call the function. This [answer](https://stackoverflow.com/questions/2674736/loading-a-dll-from-a-dll) can help – Marco Beninca May 11 '22 at 09:34

0 Answers0