Checking Serial Numbers with Administrative Installs

Got a problem you cannot solve? Try here.
Gareth Owen
Posts: 149
Joined: Fri Oct 21, 2005 8:42 am
Location: UK

Checking Serial Numbers with Administrative Installs

Postby Gareth Owen » Mon May 15, 2006 3:00 am

Hi guys, just a quick question.

We have set up some serial number checking within our installation.

but this is done during the User Interview stage, e.g. enter number, check number, if invalid, go back to enter new number.

In the case of Administrative installs, the dialogs do not appear, In fact I do not think that this section of code is even run.

Can you confirm, which parts of the code are run when doing admin installs (using the /s flag)

I actually want the user to enter the serial number as part of the Command line for the MSI,

but for this, where do I need to put my validation code, and how do I exit the MSI gracefully with some sort of logged information.

Cheers

Gareth Owen
Posts: 149
Joined: Fri Oct 21, 2005 8:42 am
Location: UK

Postby Gareth Owen » Mon May 15, 2006 3:19 am

And also,

If you run the administrative install on a PC with an old version of the software, there is no obvious information about what is happening.

In our case, the installation just quits without any further information.


Is this something to do with Instances?

Cheers

MichaelNesmith
Posts: 3452
Joined: Thu Dec 22, 2005 7:17 pm
Contact:

Postby MichaelNesmith » Mon May 15, 2006 4:14 am

The /s switch runs setup silently. Default values will be used for all dialog fields. You can pass different values when running from the command line, see the help file topic "setup command line parameters" for details.
Michael Nesmith
InstallAware
Home of The Next Generation MSI Installer
Get your free copy today - http://www.installaware.com/

Gareth Owen
Posts: 149
Joined: Fri Oct 21, 2005 8:42 am
Location: UK

Postby Gareth Owen » Mon May 15, 2006 7:49 am

So does it actually run the code in the dialog section?

In our case, after the reg dialog, the serial number is checked, if it is invalid, the serial number dialog would normally be re-displayed.

In the /s install, what would happen.

1) It ignores ALL the code in the dialog section, (from where to where?)
2) It runs the code but just does not display the dialog itself, (getting stuck in an infinite loop if the serial is invalid?)


Cheers

MichaelNesmith
Posts: 3452
Joined: Thu Dec 22, 2005 7:17 pm
Contact:

Postby MichaelNesmith » Mon May 15, 2006 3:05 pm

It would start looping infinitely, yes. Dialogs are all skipped with default values.
Michael Nesmith

InstallAware

Home of The Next Generation MSI Installer

Get your free copy today - http://www.installaware.com/

Gareth Owen
Posts: 149
Joined: Fri Oct 21, 2005 8:42 am
Location: UK

Postby Gareth Owen » Tue May 16, 2006 1:33 am

What I need to know is where exactly i need to put my validation code so that it will get run during a silent install.

At what point does the installation continue after the dialogs?

As a further point, is there a variable to determine if a silent install is taking place?

It would be useful if I can catch the silent installs and run a different validation script.

Cheers

MichaelNesmith
Posts: 3452
Joined: Thu Dec 22, 2005 7:17 pm
Contact:

Postby MichaelNesmith » Tue May 16, 2006 11:38 am

All of these are documented:

The SILENT variable indicates whether setup is running in silent mode, and can even be overriden (see pre-defined variables in help).

The topic "setup command line parameters" has examples of specifying variable values from the command line (such as your serial numbers).
Michael Nesmith

InstallAware

Home of The Next Generation MSI Installer

Get your free copy today - http://www.installaware.com/

Gareth Owen
Posts: 149
Joined: Fri Oct 21, 2005 8:42 am
Location: UK

Postby Gareth Owen » Tue May 16, 2006 2:07 pm

Thanks for the SILENT var :)

I have already managed to pass the serial number into the build, but I am still not sure exactly which bits get ignored.

is it just the Display Dialog being suppressed, or is the whole User Interview section skipped?

I have not managed to find this information in the help.


Cheers

MichaelNesmith
Posts: 3452
Joined: Thu Dec 22, 2005 7:17 pm
Contact:

Postby MichaelNesmith » Tue May 16, 2006 8:58 pm

Nothing in your code is skipped. Dialogs, message boxes are just not shown.
Michael Nesmith

InstallAware

Home of The Next Generation MSI Installer

Get your free copy today - http://www.installaware.com/

Gareth Owen
Posts: 149
Joined: Fri Oct 21, 2005 8:42 am
Location: UK

Postby Gareth Owen » Wed May 17, 2006 1:29 am

Ok, thanks that makes my life much easier.

:D

Is there also a way to log this information to the log file?
How would you normally indicate an installation failure in a silent install?

Cheers


Return to “Technical Support”

Who is online

Users browsing this forum: No registered users and 166 guests