PDA

View Full Version : Syntax for calling DLL functions



Unregistered
05-11-2007, 09:44 AM
I think I can see how to include my own DLL, and call its functions, except that I can't see how to input the argument and return value types (in particular the return value type) and assign the return value to a variable. In C++ my function (the first one I want to use) is

DWORD _stdcall Function()

(no arguments).

David Webber

[I may be running before I can walk here but I have been doing this sort of thing for ages with an old version of Wise Install Builder, which I'm now looking to replace.]

linder
05-11-2007, 10:14 AM
David,

Just leave Parameter Types and Function Parameters emtpy :)

For example (in this case, call to a Windows API):

Call DLL "kernel32.dll" -- Function "GetUserDefaultLCID" () ()

The %_SB_RETURN% variable holds the return value.

BTW, there are interesting example scripts in the Examples package.

http://www.lindersoft.com/sb6_Examples.exe

We'll make new SetupBuilder 6.5 examples available next week.

Does this help?

Friedrich