Wise Installation Studio/Express Getting Started Guide
34
Advanced Tutorial: Using MSI Script in a Windows Installer Installation
10. Click OK on the Call Custom DLL From Destination dialog box.
The action is added to the sequence, immediately after the MoveFiles action. The
next steps demonstrate how to enclose the new action in an If Statement, which
sets a condition on the action—the action runs only if the condition is true.
11. Select the Call Custom DLL From Destination action that you just created, and then
in the Actions list, double-click If Statement.
The If Settings dialog box appears.
12. In If Condition, enter NOT Installed (case sensitive) and click OK.
The Windows Installer property named Installed is true if the product is already
installed, so this action will run only on the initial installation of the product, not on
subsequent maintenance installations. See Installed Property in the Windows
Installer SDK Help.
13. Select the line below the Call Custom DLL From Destination action and double-click
End Statement in the Actions list.
This encloses the custom action in an If block, which is located between MoveFiles
and InstallFiles and should look like the image below. If not, double-click the actions
to edit their settings or use the Move Up and Move Down commands on the right-
click menu to rearrange the lines.
To test the custom action
1. Save the installation.