I tried transitive and it doesn't seem to work, from what I can tell the components cannot be removed by a condition. So although my 2 components were exclusive they both ended up installed after a Change.
I am trying Bobs idea of setting REINSTALL, it seems to work expect I am having trouble on uninstall (I just need to get a condition correct). Neil -----Original Message----- From: Wilson, Phil [mailto:[EMAIL PROTECTED] Sent: 13 November 2008 20:51 To: General discussion for Windows Installer XML toolset. Subject: Re: [WiX-users] Always Reinstall a Component You can make them mutually exclusive by making them transitive and conditioned on a properties that have mutually exclusive values. For example, the old-ish ATL merge module has two components with identical component guids, each with an identical file being installed to the same location. One is conditioned on Version9X the other on VersionNT so they can't be on the system at the same time. Phil Wilson -----Original Message----- From: Neil Sleightholm [mailto:[EMAIL PROTECTED] Sent: Thursday, November 13, 2008 9:51 AM To: General discussion for Windows Installer XML toolset. Subject: Re: [WiX-users] Always Reinstall a Component I have tried more than one component but I can't see how you would make them mutually exclusive. To do this you would need some way of installing a component if it is not in a feature which as far as I can tell is not possible. I have tried conditions on components but they only stop the component being installed if it is already being installed by a feature. When I approached this it seemed a really simple requirement - all I want was "set registry key to 1 if feature selected, set to 0 if not". It works ok on initial install but seem impossible on "Change". Neil -----Original Message----- From: Wilson, Phil [mailto:[EMAIL PROTECTED] Sent: 13 November 2008 17:26 To: General discussion for Windows Installer XML toolset. Subject: Re: [WiX-users] Always Reinstall a Component The basic issue here is that the component is already installed, and while you are in maintenance mode any consideration of REINSTALLMODE doesn't help. You're just adding and removing features and components. I think the answer is likely to be that you need more than one component, perhaps one per feature, each with the appropriate registry values, and make sure that they are mutually exclusive. I assume your maintenance mode is adding or removing features and therefore adding and removing components. Using transitive components might help too if you can arrange for one component to become absent when the other becomes present. Phil Wilson -----Original Message----- From: Gavin Bee [mailto:[EMAIL PROTECTED] Sent: Tuesday, November 11, 2008 12:27 PM To: 'General discussion for Windows Installer XML toolset.' Subject: Re: [WiX-users] Always Reinstall a Component Yes windows installer is detecting that the keypath is still there and deciding that no action is required for the component. What I want to do is cause the component to be reinstalled even if the keypath registry value still exists. I can think of a couple of hacks: * Delete the keypath registry value before InstallInitialize * Treat any change as a major upgrade and run "RemoveExistingProducts" to silently uninstall first. I have been trying to get this working using conditions and/or keypaths as that seems like the "right" thing to do. What am I missing? Thanks, Gavin :) -----Original Message----- From: Rob Mensching [mailto:[EMAIL PROTECTED] Sent: Tuesday, November 11, 2008 12:49 PM To: General discussion for Windows Installer XML toolset. Subject: Re: [WiX-users] Always Reinstall a Component The KeyPath of the Component controls whether it is installed or not. The MSI SDK talks about KeyPaths in detail. A verbose log file should give you a pretty good idea what the Windows Installer has decided to do with your Component. -----Original Message----- From: Gavin Bee [mailto:[EMAIL PROTECTED] Sent: Monday, November 10, 2008 20:08 To: wix-users@lists.sourceforge.net Subject: [WiX-users] Always Reinstall a Component We have a WIX v3 installer and are trying to force a component that contains only registry values to reinstall when the user presses “change” in Add/Remove programs. The registry values are populated from properties that are set by our installer UI and can be changed when running the installer again. (See details below) The UI correctly prompts for new values but they are not saved to the registry. This appears to be because the component is not reinstalled. Among other things, I have tried making the component transitive with various conditions similar to: NOT Installed OR $component <> 2 NOT Installed OR REINSTALL NOT Installed OR $component = 3 It seems like there should be a way to force a component or a feature to reinstall. Have I missed something? How is this supposed to work? We really just want the property values set in our installer UI to be saved to the registry. It seems like this should be easy, but I have been unable to find a good example of how to do this. Thanks, Gavin ☺ <Feature Id="Client" Title="Base Install" Level="1"> <ComponentRef Id="ClientRegistryKeys" /> </Feature> … <Component Id="ClientRegistryKeys" Guid="{aguid}"> <RegistryKey Action="createAndRemoveOnUninstall" Root="HKLM" Key="SOFTWARE\Microsoft\Windows\CurrentVersion\Run" > <RegistryValue Id="AutoStart" Type="string" Name="AutoStart" Value="[INSTALLLOCATION]\app.exe [VALUEFROMUI]" /> </RegistryKey> </Component> … <UI Id="WixUI_ClientDialogs"> … <Publish Dialog="ClientParametersDlg" Control="Next" Event="NewDialog" Value="VerifyReadyDlg">1</Publish> … <Publish Dialog="MaintenanceTypeDlg" Control="ChangeButton" Event="NewDialog" Value="ClientParametersDlg">1</Publish> … <Dialog Id="ClientParametersDlg" Title="[ProductName] Setup"> … <Control Id="Next" Type="PushButton" Height="17" Text="Next" /> … <Control Id="ValueFromUIEdit" Type="Edit" Property="VALUEFROMUI" /> … </Dialog> </UI> ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ _______________________________________________ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ _______________________________________________ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ _______________________________________________ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ _______________________________________________ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ _______________________________________________ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ _______________________________________________ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ _______________________________________________ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users