installshield| program//////////////////////////////////////////////////////////////////////////////
//
Function:onfirstuiafter
//
Event:firstuiafter event is sent after file transfer, when installation
is run for the "the" "the" given machine. In this event handler
Installation usually displays UI that would inform end user
Installation has been completed successfully.
//
///////////////////////////////////////////////////////////////////////////////
function Onfirstuiafter ()
STRING SzTitle, SZMSG1, SZMSG2, SzOption1, Szoption2,szcmdline;
Number BOPT1, BOpt2;
Begin
szCmdLine = TARGETDIR ^ "Mkwebdir.vbs" + "-C localhost-w 1-v WebApp," + TARGETDIR;
if (launchappandwait ("WScript.exe", szcmdline,wait) < 0) Then
MessageBox ("Cannot establish a Web virtual directory.", SEVERE);
endif
Disable (Statusex);
BOPT1 = FALSE;
BOpt2 = FALSE;
SZMSG1 = sdloadstring (IFX_SDFINISH_MSG1);
SZMSG2 = "";
SzOption1 = "";
SzOption2 = "";
SzTitle = "";
Sdfinishex (SZTITLE,SZMSG1,SZMSG2,SZOPTION1,SZOPTION2,BOPT1,BOPT2);
return 0;
End
//////////////////////////////////////////////////////////////////////////////
//
Function:onmaintuibefore
//
Event:maintuibefore event is sent as end user runs installation that
has already been installed on the machine. Usually this happens
Through Add/remove Programs applet. In the handler installation
Usually displays UI allowing end user to modify existing installation
or uninstall application. After this function returns,
Componenttransferdata is called to perform file transfer.
//
///////////////////////////////////////////////////////////////////////////////
function Onmaintuibefore ()
Number Nresult,nlevel,ntype;
STRING sztitle,szmsg,svdir,szcomponents,svresult,szcaption;
Begin
To do:if your want to enable background, window title, and caption bar title
Settitle (@TITLE_MAIN, white);
Settitle (@TITLE_CAPTIONBAR, 0, backgroundcaption);
SetColor (Background,rgb (0, 128, 128));
Enable (Fullwindowmode);
Enable (BACKGROUND);
Ntype = MODIFY;
Dlg_start:
Disable (Backbutton);
Nresult = Sdwelcomemaint (SzTitle, szmsg, ntype);
Enable (Backbutton);
Dlg_sdcomponenttree:
if (nresult = MODIFY) Then
SzTitle = "";
szmsg = "";
Svdir = TARGETDIR;
Szcomponents = "";
Nlevel = 2;
Nresult = Sdcomponenttree (SzTitle, szmsg, Svdir, szcomponents, nlevel);
if (nresult = back) goto Dlg_start;
Setup Default Status
Setstatuswindow (0, "");
Enable (Statusex);
Statusupdate (on, 100);
ElseIf (nresult = removeall) Then
Svresult = sdloadstring (ifx_maintui_msg);
Szcaption = sdloadstring (ifx_onmaintui_caption);
Nresult = Sprintfbox (mb_okcancel,szcaption, "%s", Svresult);
if (nresult = IDCANCEL) Then
Goto Dlg_start;
ElseIf (nresult = Idok) Then
Setup Default Status
Setstatuswindow (0, "");
Enable (Statusex);
Statusupdate (on, 100);
-->remove All components
Componentremoveall ();
endif
ElseIf (nresult = REPAIR) Then
Setup Default Status
Setstatuswindow (0, "");
Enable (Statusex);
Statusupdate (on, 100);
-->reinstall Logged Components
Componentreinstall ();
endif
End
///////////////////////////////////////////////////////////////////////////////
//
Function:onmaintuiafter
//
Event:maintuiafter event is sent after file transfer, as end user runs
Installation that has already been installed on the machine. Usually
This happens through Add/remove Programs applet.
In the handler installation usually displays UI that would inform
End user that Maintenance/uninstallation has been completed successfully.
//
///////////////////////////////////////////////////////////////////////////////
function Onmaintuiafter ()
STRING SzTitle, SZMSG1, SZMSG2, SzOption1, SzOption2;
Number BOPT1, BOpt2;
Begin
Disable (Statusex);
BOPT1 = FALSE;
BOpt2 = FALSE;
SZMSG1 = sdloadstring (IFX_SDFINISH_MAINT_MSG1);
SZMSG2 = "";
SzOption1 = "";
SzOption2 = "";
SzTitle = sdloadstring (Ifx_sdfinish_maint_title);
Sdfinishex