How can I create a dll in which a procedure gives me a value back?
Could you post me an exampel procedure?

Posted on 2002-12-27 04:59:42 by Alunitro3078
Okie dokie. I'm sure there's many ways to do it, but you could for example have in your program source:

SomeFunction proto :DWORD

includelib myDll.lib

And of course, in your dll you declare the function proto and the write the proc as per normal:

SomeFunction proto :DWORD
SomeFunction proc asdf:DWORD
; Insert goodies here :)
mov eax, theReturnValue
SomeFunction endp

Export the function as per Iczelion's DLL tutorial, and you're free to call SomeFunction from your program. Once again, refer to Iczelion's tut on how to do this using LoadLibrary if you so desire.

Hope this helps (it'd be nice if I could contribute even a little to this great board)
Posted on 2002-12-27 06:06:29 by Miko
thats what I wanted :)
Posted on 2002-12-27 06:30:57 by Alunitro3078