MSI installs without installedcheck and dialog pops up at end

Nov 19, 2010 at 3:53 PM

I have a bootstrapper with an exe and an msi. I have auto-start set to true and do not have an installed check on the msi because I want to be able to double click the bootstrapper and have it go right to the repair/remove screen of the msi. In addition with the latest 2.0 version, uninstall without an installed check works from the command line using /x. This is great.

I have one problem still. In 2.0 after the msi finishes installing and we're all done, the bootstrapper pops a dialog saying the msi is required to install. I understand it's probably because there's no installed check and the msi is listed as required but why assume the msi is not installed if there's no installed check after we already ran the msi?


Is there a way I can just tell the bootstrapper to be done after it goes through its routine instead of trying to say something is not installed? I tried making the msi not required yet selected but met with failure. The bootstrapper then attempts a uninstall by default. If there is a way to have an installedcheck and still facilitate getting to the repair screen it would be ok as well.

Developer
Nov 19, 2010 at 6:14 PM

If you use an installedcheck, set supports_install="True" and set supports_uninstall="True" and specify a command and an uninstall_command that point to your msi, does that work for you?

You can also set the uninstall_caption to "Modify" for example so that the user can use it to perform a repair\reinstall\uninstall.

Nov 19, 2010 at 6:20 PM

Hi icnocop,

"You can also set the uninstall_caption to "Modify" for example so that the user can use it to perform a repair\reinstall\uninstall."

To clarify, are you saying the string "Modify" is specifically tested for by DNI? If this is the case, is it documented somewhere? I'd like to know all the strings that DNI checks for like this.

Developer
Nov 19, 2010 at 6:37 PM

No, "Modify" is just used for the caption (text) on the button.  By default it is "Install" for the install sequence and "Uninstall" for the uninstall sequence.

If you set the button to display "Modify", instead of "Uninstall", it may be a better fit for users who may wish to perform a "Repair" for example.

Nov 19, 2010 at 6:50 PM

Thanks for clearing that up about the text of the button.

 


"and specify a command and an uninstall_command that point to your msi, does that work for you?"

Ok I see three properties to edit uninstall_cmdparameters. They are uninstall_cmdparameters, uninstall_cmdparameters_basic and uninstall_cmdparameters_silent. These are all for command line arguments that go after the msi file in the msiexec command line. I need to change the /x to /i. How may I do that?

Developer
Nov 19, 2010 at 8:48 PM

I just found out that the /x parameter is hard-coded and cannot be changed.

I created a work-item here:

http://dotnetinstaller.codeplex.com/workitem/7703

A work-around is to use an exe component instead and use msiexec.exe as the command for example.

Nov 19, 2010 at 8:51 PM

Alright thanks. I'll try out the work around.

Coordinator
Nov 22, 2010 at 12:58 PM

Maybe the best route is the hardest one: to support repair? That's a broad, but rather easy change in the code following the same model as uninstall. Then we could define what the bootstrapper should switch to by default (probably repair as MSIs do).

Nov 22, 2010 at 1:29 PM

I agree having built in repair support would be good. 

I've implemented your work around using a cmd component and am very pleased with the results. This way I can use msiexec /i or msiexec /x exactly how I want for the 6 different command line properties. As of now I have no other issues.

Thanks a lot.