What happened to the Messenger Plus! forums on msghelp.net?
Shoutbox » MsgHelp Archive » Skype & Technology » Tech Talk » Getting unmanaged dll function params

Getting unmanaged dll function params
Author: Message:
J-Thread
Full Member
***

Avatar

Posts: 467
Reputation: 8
– / Male / –
Joined: Jul 2004
O.P. Getting unmanaged dll function params
I'm developing a plugin for msn, but my question isn't related to it directly so I ask it here...

I've got an unmanaged DLL (I guess it's written in C++). I've got some tools to view a list of functions that are in it. The function names describe the function good I hope, and there are some functions I would really like to use in my code. So I want to call them from my C# application. Of course I know I can call external functions like this:

[DllImport("MyDLL.DLL"]
public static extern bool ANiceFunction(String param);

But the problem is, I don't know the return type (bool in example above) and I don't know the params...  I can guess the return type sometimes, but not always... I tried some things but I haven't been able to get a good reaction of the dll (for example when I try int as return type it always returns 0, although I expected 1 or 2)...

I don't think it is possible, but is there a way to detect what params and/or what return type the functions have?? I doesn't have to be C#, if there is another way to detect it, it is fine by me. Or is there a code that just tries several options and can tell me which is correct? It would really help me!!

P.S. There is absolutely no documentation about this dll so I have to find it myself...
08-06-2005 08:34 AM
Profile E-Mail PM Find Quote Report
« Next Oldest Return to Top Next Newest »

Messages In This Thread
Getting unmanaged dll function params - by J-Thread on 08-06-2005 at 08:34 AM
RE: Getting unmanaged dll function params - by segosa on 08-06-2005 at 03:37 PM
RE: Getting unmanaged dll function params - by J-Thread on 08-06-2005 at 05:24 PM
RE: Getting unmanaged dll function params - by segosa on 08-06-2005 at 07:17 PM
RE: Getting unmanaged dll function params - by RaceProUK on 08-06-2005 at 07:20 PM
RE: Getting unmanaged dll function params - by J-Thread on 08-06-2005 at 08:01 PM
RE: Getting unmanaged dll function params - by RaceProUK on 08-06-2005 at 08:13 PM
RE: Getting unmanaged dll function params - by J-Thread on 08-06-2005 at 08:44 PM
RE: Getting unmanaged dll function params - by RaceProUK on 08-06-2005 at 08:45 PM
RE: Getting unmanaged dll function params - by segosa on 08-07-2005 at 08:53 AM
RE: Getting unmanaged dll function params - by J-Thread on 08-07-2005 at 08:59 AM
RE: Getting unmanaged dll function params - by RaceProUK on 08-07-2005 at 04:55 PM


Threaded Mode | Linear Mode
View a Printable Version
Send this Thread to a Friend
Subscribe | Add to Favorites
Rate This Thread:

Forum Jump:

Forum Rules:
You cannot post new threads
You cannot post replies
You cannot post attachments
You can edit your posts
HTML is Off
myCode is On
Smilies are On
[img] Code is On