This website uses cookies. By clicking Accept, you consent to the use of cookies. Click Here to learn more about how we use cookies.
Turn on suggestions
Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.
- Revenera Community
- :
- InstallShield
- :
- InstallShield Forum
- :
- Re: Custom dialog problem in Basic MSI
Subscribe
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Subscribe
- Mute
- Printer Friendly Page
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
Aug 14, 2008
06:10 AM
Custom dialog problem in Basic MSI
Hi,
I use a custom dialog in install script project, now it migrates to Basic MSI. I use dialog export wizard to add custom dialog in a new project (Export to Dialog File). I create a custom installscript action and try to use custom dialog:
function SetWorkDBs (svInstallINI,DBIDList)
STRING szDialogName, szDLLName, szDialog;
NUMBER nDialog, nResult, nCmdValue, nId;
BOOL bDone;
HWND hInstance, hwndParent;
begin
szDialogName = "Dialog Title";
hInstance = 0;
szDLLName = "";
szDialog = "";
hwndParent = 0;
nId = 13854;
nResult = DefineDialog (szDialogName, hInstance, szDLLName,
nId, szDialog, hwndParent,
HWND_INSTALL, DLG_MSG_STANDARD|DLG_CENTERED);
if (nResult < 0) then
MessageBox ("An error occurred while defining the dialog.", SEVERE);
bDone = TRUE;
abort;
endif;
bDone = FALSE;
repeat
nCmdValue = WaitOnDialog(szDialogName);
switch (nCmdValue)
case DLG_CLOSE:
Do (EXIT);
case DLG_ERR:
MessageBox ("Unable to display dialog. Setup canceled.", SEVERE);
abort;
case DLG_INIT:
MessageBox ("Success", SEVERE);
endswitch;
until bDone;
EndDialog (szDialogName);
ReleaseDialog (szDialogName);
end;
The dialog is not displayed because WaitOnDialog returns -1.
I try to set szDLLName = ISUSER, in this case DefineDialog returns -1 (Using degug mode I found out that there is no _isuser.dll in SUPPORTDIR during installation)
Did I make any mistakes?
I use a custom dialog in install script project, now it migrates to Basic MSI. I use dialog export wizard to add custom dialog in a new project (Export to Dialog File). I create a custom installscript action and try to use custom dialog:
function SetWorkDBs (svInstallINI,DBIDList)
STRING szDialogName, szDLLName, szDialog;
NUMBER nDialog, nResult, nCmdValue, nId;
BOOL bDone;
HWND hInstance, hwndParent;
begin
szDialogName = "Dialog Title";
hInstance = 0;
szDLLName = "";
szDialog = "";
hwndParent = 0;
nId = 13854;
nResult = DefineDialog (szDialogName, hInstance, szDLLName,
nId, szDialog, hwndParent,
HWND_INSTALL, DLG_MSG_STANDARD|DLG_CENTERED);
if (nResult < 0) then
MessageBox ("An error occurred while defining the dialog.", SEVERE);
bDone = TRUE;
abort;
endif;
bDone = FALSE;
repeat
nCmdValue = WaitOnDialog(szDialogName);
switch (nCmdValue)
case DLG_CLOSE:
Do (EXIT);
case DLG_ERR:
MessageBox ("Unable to display dialog. Setup canceled.", SEVERE);
abort;
case DLG_INIT:
MessageBox ("Success", SEVERE);
endswitch;
until bDone;
EndDialog (szDialogName);
ReleaseDialog (szDialogName);
end;
The dialog is not displayed because WaitOnDialog returns -1.
I try to set szDLLName = ISUSER, in this case DefineDialog returns -1 (Using degug mode I found out that there is no _isuser.dll in SUPPORTDIR during installation)
Did I make any mistakes?
(2) Replies
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
Aug 14, 2008
10:35 AM
Before going down that road, is it an option to create a custom MSI dialog box? Custom InstallScript dialog boxes don't integrate very well with Basic MSI projects...
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
Aug 15, 2008
02:52 AM
I call custom dialog in deferred custom action (I understand that it is impossible to use MSI dialog). Now I have alternative solution: I create dialog in Visual C++ Editor and save it in resourсe dll and include this file in component of installation. But it is not very convinient, is it possible, for example, to add this dialog in _isres.dll?