PDA

View Full Version : License Agreement Dialog Box



babytaz1927288
10-28-2003, 04:29 PM
hey im having a problem with the License Agreement Dialog Box in installscript msi, i can get the box to work just fine but its placing it before the welcome dialod box and i want the license box after the welcome box is there any way i can change this?????:confused:

RichAquino
10-28-2003, 05:03 PM
Hi,

There's probably just a problem in your script. Can you post the portion of your script that has SdWelcome and SdLicense?

Rich

babytaz1927288
10-28-2003, 05:25 PM
well its not configured in my script i have in in the support files right now but when i try to configure it in my script, it wont show it but if you would please help me to configure it i want it to be configured after my welcome screen heres the script

Dlg_SdWelcome:
szTitle = "";
szMsg = "";
nResult = SdWelcome(szTitle, szMsg);
if (nResult = BACK) goto Dlg_SdWelcome;

szTitle = "";
svName = "";
svCompany = "";



Dlg_SdCustomerInformation:
nResult = SdCustomerInformation(szTitle, svName, svCompany, nUser);
if (nResult = BACK) goto Dlg_SdWelcome;

Dlg_SetupType:
szTitle = "";
szMsg = "";
nResult = SetupType(szTitle, szMsg, "", nSetupType, 0);
if (nResult = BACK) then
goto Dlg_SdCustomerInformation;
else
nSetupType = nResult;
if (nSetupType != CUSTOM) then
nvSize = 0;
FeatureCompareSizeRequired(MEDIA, INSTALLDIR, nvSize);
if (nvSize != 0) then
MessageBox(szSdStr_NotEnoughSpace, WARNING);
goto Dlg_SetupType;
endif;
bCustom = FALSE;
goto Dlg_SdStartCopy;
else
bCustom = TRUE;
endif;
endif;

Dlg_SdAskDestPath:
nResult = SdAskDestPath(szTitle, szMsg, INSTALLDIR, 0);
if (nResult = BACK) goto Dlg_SetupType;

Dlg_SdFeatureTree:
szTitle = "";
szMsg = "";
if (nSetupType = CUSTOM) then
nResult = SdFeatureTree(szTitle, szMsg, INSTALLDIR, "", 2);
if (nResult = BACK) goto Dlg_SdAskDestPath;
endif;

Dlg_SdStartCopy:
szTitle = "";
szMsg = "";
listStartCopy = ListCreate( STRINGLIST );
//The following is an example of how to add a string(svName) to a list(listStartCopy).
//eg. ListAddString(listStartCopy,svName,AFTER);
nResult = SdStartCopy( szTitle, szMsg, listStartCopy );
ListDestroy(listStartCopy);

if (nResult = BACK) then
if (!bCustom) then
goto Dlg_SetupType;
else
goto Dlg_SdFeatureTree;
endif;
endif;

please help:confused:

RichAquino
10-28-2003, 05:37 PM
Hi,

The license agreement dialog must be displaying somehow. There's a very slight possibility that it's coming up via the MSI tables.

If you look at the Sequences view, then look under the Installation\User Interface node, do you see any dialogs there?

If you don't, then the dialog is probably being displayed via script. Search for the strings "SdLicense" or just "License".

You'll want your code to look something like this:

Dlg_SdWelcome:
szTitle = "";
szMsg = "";
nResult = SdWelcome(szTitle, szMsg);
if (nResult = BACK) goto Dlg_SdWelcome;

szTitle = "";
svName = "";
svCompany = "";

Dlg_SdLicense:
nResult = SdLicense(...)
if (nResult = BACK) goto Dlg_SdWelcome;

Dlg_SdCustomerInformation:
nResult = SdCustomerInformation(szTitle, svName, svCompany, nUser);
if (nResult = BACK) goto Dlg_SdLicense;


Rich

babytaz1927288
10-28-2003, 05:46 PM
Hey Rich i couldnt find any dialogs under the sequence so i did a search in the script like u said and i found this

function OnFirstUIBefore()
NUMBER nResult, nSetupType, nvSize, nUser;
STRING szTitle, szMsg, szQuestion, svName, svCompany, szFile;
STRING szLicenseFile;
LIST list, listStartCopy;
BOOL bCustom;

the szLicenseFile; is being displayed before my welcome is it gonna hurt anything if i get rid of it and use what u suggusted under the welcome dialog

RichAquino
10-28-2003, 05:50 PM
Hi,

That's just a variable declaration. It won't hurt anything if you delete it (or just comment it out).

Rich

babytaz1927288
10-28-2003, 05:53 PM
hey rich i configured the license dialog like u said and im getting a error with this line

nResult = SdLicense(...)

error code is C0834 missing expression

RichAquino
10-28-2003, 05:59 PM
Hi,

The "..." isn't the correct code. You'll have to fill that in with the appropriate arguments.

Rich

babytaz1927288
10-28-2003, 06:12 PM
hey rich so should i put this in

SdLicense ( szTitle, szMsg, szQuestion, szLicenseFile );

RichAquino
10-28-2003, 06:16 PM
Hi,

You'll need to specify the license file.

If you want to just accept the default title, message, and question; you can just use null strings for those values. You'll need to specify the license file though. Try something like this:

nResult = SdLicense ( "", "", "", SUPPORTDIR ^ "License.txt");

Rich

babytaz1927288
10-28-2003, 06:22 PM
hey rich i did it just like you said compiled it and it had no errors and when i run it i still can not get a License agreement box is there anything else we can try or do please help:confused:

RichAquino
10-28-2003, 06:25 PM
Hi,

I would suggest that you use the debugger.

Rich

babytaz1927288
10-28-2003, 06:55 PM
hey rich thank you for all you help i made a new project up and i finally got it all straight, oh theres something else i wanted to ask you is there any way to change the preparing to install dialog box? :)

RichAquino
10-29-2003, 01:16 PM
Hi,

Other than deciding whether to use the large or small version (which is a release setting), the setup initialization dialog (i.e. preparing to install) cannot be changed.

Rich

babytaz1927288
10-29-2003, 03:05 PM
Hey Rich thank you for all you help!!! :D :D