WiseScript Editor Reference
46
WiseScript Actions
Call DLL Function
This action calls a .DLL function from a .DLL on the destination computer. They can be
be .DLLs you have written, .DLLs developed for WiseScript, or Windows .DLLs. You can
branch the script based on the returned results of a .DLL by setting the Action to Start
Block if Return Value True or Start While Loop.
When a WiseScript is called by a Windows Installer installation, you can also call a .DLL
by using one of the Call Custom DLL or Call DLL actions in MSI Script in Windows
Installer Editor.
To complete the dialog box
z
DLL Pathname
Specify the path of the .DLL file (example: %MAINDIR%\Jso32.dll).
For non-system .DLLs, the installation script must install the .DLL before the script
calls it or it will not be found. If the .DLL is only needed temporarily during
installation, copy it to the Temp directory, represented by %TEMP%.
Note
You cannot test an installation that installs and immediately calls a .DLL unless you
install the .DLL to the Temp directory. Testing installs files, then immediately
deletes them, unless they are installed to the Temp directory.
z
Function Name
Enter the name of the function to call. The function should be exported when
creating the .DLL. The function’s parameters and return value must exactly match
those specified below (case-sensitive).
z
Call a function written specifically for WiseScript
When calling functions developed specifically for WiseScript, mark this option and fill
in Variables Added, Parameter String, and Action below.
Each .DLL function takes a single parameter (lpDllParams) that points to a structure
containing information that can be passed back and forth between the .DLL function
and the running installation script.
z
Variables Added
Because WiseScript-specific .DLL functions have access to the variable list of the
running installation, you can add new variables. List the names of the variables to
add, separated by commas. Do not use variables enclosed in %.
z
Parameter String
Use this to pass information to the .DLL function. Text you enter here is passed to
the .DLL in the IpszParam variable. This can include variables surrounded with %
signs.
z
Action
Select the installation’s action when it returns from the .DLL call. The .DLL returns a
boolean value (zero equals false, non-zero equals true).
Ignore return value
The script continues regardless of any value returned.
Exit if function returns true
The installation exits if the .DLL function returns non-zero.