User Guide

472
OLE Automation Function Reference
QueryDisplayValidation
Use the QueryDisplayValidation event in a macro to suppress the display of Package
Validation error messages associated with individual Internal Consistency Evaluators
(ICE).
QueryFixValidation
Use the QueryFixValidation event to customize how individual Internal Consistency
Evaluators (ICE) errors are resolved in Package Validation.
RunScriptMacro
Executes a named macro from the current script file. UseScriptFile must be called prior
to calling this function. The RunScriptMacro function should only be called from an
external Visual Basic or VB program.
Save
Saves the current Windows Installer file to the given location. Does not compile project
files (.WSI, .WSM).
Function
Prototype
void QueryDisplayValidation(short sType, long IceNumber, BSTR strDescription, BSTR
strTable, BSTR strColumn, BSTR strKey, VARIANT* bDisplay)
Parameters sType: 0 error, 1 warning, 2 logo (Wise-generated)
IceNumber: The number from the SDK of the ICE that was executed
strDescription: String description of the error
strTable: Table name where error occurred (optional)
strColumn: Column in table where error occurred (optional)
strKey: Key value of row where error occurred (optional)
bDisplay: Set to true by default. Specifies whether to display the error or not in the
interface. The end user can set this to FALSE to ignore the error.
Function
Prototype
void QueryFixValidation(short sType, long IceNumber, BSTR strDescription, BSTR strTable,
BSTR strColumn, BSTR strKey, BOOL bCheckOnly,VARIANT* bFix)
Parameters sType: 0 error, 1 warning, 2 logo (Wise-generated)
IceNumber: The number from the SDK of the ICE that was executed
strDescription: String description of the error
strTable: Table name where error occurred (optional)
strColumn: Column in table where error occurred (optional)
strKey: Key value of row where error occurred (optional)
bCheckOnly: Set to true when querying the macro code whether it is possible to fix an
error. Set to FALSE when the error is to be fixed by the macro code.
bFix: Set to false by default. If bCheckOnly is true, the code can set to true if the error is
fixable by the macro. If bCheckOnly is false, set bFix to true if the macro code fixed the
error.
Function Prototype void RunScriptMacro(BSTR bsMacroName)
Parameters bsMacroName: case-sensitive name of the macro to run