runtime option to turn on logged execution?

Got a problem you cannot solve? Try here.
Post Reply
wolbrink
Posts: 76
Joined: Wed Nov 17, 2004 3:00 pm

runtime option to turn on logged execution?

Post by wolbrink »

It's a bit cumbersome to have an end user run "setup.exe /l=c:\\log.txt" in order to get a log file. I was wondering if it were possible within my installation program to turn on logging within the ui, as an option. I'm thinking I'd discretely provide this option on the first wizard page before anything that interesting actually happens. Is this possible? If so, how might I best get started adding this.

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

Post by MichaelNesmith »

There's a pre-defined variable for this, LOGGED. please look in the help index for pre-defined variables for details.
Michael Nesmith
Install[b]Aware[/b]
[i]Home of The Next Generation MSI Installer[/i]
Get your free copy today - http://www.installaware.com/
wolbrink
Posts: 76
Joined: Wed Nov 17, 2004 3:00 pm

Post by wolbrink »

MichaelNesmith wrote:There's a pre-defined variable for this, LOGGED. please look in the help index for pre-defined variables for details.
That's exactly what I needed. Thanks!

In my script, I'll check to see if it's blank. If it is blank (ie. the user hasn't specified it on the command line parameter), I'll generate a temporary file to use. Then at the end of the installation, I'll have a button to "View Log..." which will open it in notepad. In other words, I'll always be logging my installation, just in case it's actually needed.

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

Post by MichaelNesmith »

This is not recommended. Logging your setup significantly slows down the speed of your installation. It might be OK on small projects, but you really don't want to do it unless you have to.
Michael Nesmith
Install[b]Aware[/b]
[i]Home of The Next Generation MSI Installer[/i]
Get your free copy today - http://www.installaware.com/
wolbrink
Posts: 76
Joined: Wed Nov 17, 2004 3:00 pm

Post by wolbrink »

MichaelNesmith wrote:This is not recommended. Logging your setup significantly slows down the speed of your installation. It might be OK on small projects, but you really don't want to do it unless you have to.
You're right! It's really slow with logging! I'll provide the option via a check box before the installation begins.

--Troy
Post Reply