InstallShield 2016 » InstallScript Language Reference
Note • To call this function in a Basic MSI setup, you must first create a custom action for the entry-point function, execute the custom action in a sequence or as the result of a dialog's control event, and then build the release.
/*--------------------------------------------------------------*\
*
* InstallShield Example Script
*
* Demonstrates the GetExtents function.
*
* This script calls GetExtents to obtain the current video
* resolution of the target system. It then displays that
* information in a dialog.
*
\*--------------------------------------------------------------*/
#define TITLE_TEXT "GetExtents example"
#define MSG_TEXT "Video Resolution: %d by %d"
// Include Ifx.h for built-in InstallScript function prototypes.
#include "Ifx.h"
export prototype ExFn_GetExtents(HWND);
function ExFn_GetExtents(hMSI)
NUMBER nvDx, nvDy;
begin
// Get the video resolution of the target system.
if (GetExtents (nvDx, nvDy) < 0) then
// Report the error.
MessageBox ("GetExtents failed.", SEVERE);
else
// Display the information
SprintfBox (INFORMATION, TITLE_TEXT, MSG_TEXT, nvDx, nvDy);
endif;
end;
InstallShield 2016 Help LibraryMay 2017 |
Copyright Information | Flexera Software |