Then you just broke the component rules and you enter this mess all over
again. Even worse, since the old GUID no longer exists in your updated minor
upgrade package, your component's installed feature(s) will be advertised
without being physically removed from the machine (because Windows Installer
will think you removed the component via the upgrade), orphaning the entire
feature and not changing anything in the computer. You can only get out of
that by subsequently running a repair of all effected features before
uninstalling (and you would at that point have orphaned the component you
removed).

Windows Installer uses the name of a component only within any given
package; the component's identity outside of any arbitrary package is the
combination of its GUID and its KeyPath.

Never change the GUID of a component without an associated change to the
keypath. That is a fundamental violation of the component rules. And minor
upgrades/small updates MUST always have at minimum all of the same component
guids in place and as part of the same features as the installation they are
replacing.

If you schedule RemoveExistingProducts early using a major upgrade, you can
usually get away with changing component guids at that point (such as part
of implementing Guid="*" policies) but there are cases where you can't do
that (GAC registration and VC runtime MSMs can break when scheduling
RemoveExistingProducts early). The reason is that the old component is
removed before installing the new component, so there is never two
components pointing to the same KeyPath. With late scheduling of
RemoveExistingProducts, during the middle of the transaction there are two
components pointing to the KeyPath, and the removal action will leave the
already upgraded component in place, which is why late scheduling is more
efficient (less work/time to just upgrade (or even just leave alone if the
KeyPath didn't change in the upgrade) and not first erase/rewrite the entire
world).

-----Original Message-----
From: Stelios Kyprou [mailto:stelios.kyp...@formicary.net] 
Sent: Friday, July 02, 2010 7:21 AM
To: General discussion for Windows Installer XML toolset.
Subject: Re: [WiX-users] Upgrade msi with removed components

I am aware about the product codes. What i was asking for though is 
Component GUIDs.
Can they change with each msi?
i.e.
If i have
<Component Id="comp_8F13BB8407964D13A8410C17EFAFF9FB" DiskId="1"
KeyPath="yes" Guid="D882408E-F553-41F7-A284-5BBA716F728B">
    
<File Id="file_D1CB3C8DDC7B417B9EE72858958A97D3"
Source="$(var.FilesDir)\Tools\HttpCfgAcl_Instructions.txt" />
</Component>

and i make an update installer, where the file of this component is 
unchanged, what happens if i
assign a new GUID to the component?



------------------------------------------------------------------------------
This SF.net email is sponsored by Sprint
What will you do first with EVO, the first 4G phone?
Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users

Reply via email to