If you plan to patch these files separately, I would suggest having 1
file per component. This will automatically make each file a KeyPath of
its component and you'll be able to patch naturally.

OffTopic: BTW, it would be great for the subject not to be generic, but
reflect the basic idea of the problem.

-- Yan

-----Original Message-----
From: Oleksandr Y. Nechyporenko [mailto:alexnc69...@gmail.com] 
Sent: Wednesday, September 15, 2010 19:46
To: 'General discussion for Windows Installer XML toolset.'
Subject: [WiX-users] General discussion for Windows Installer XML
toolset.

Hi All,

 

I have a following question.

 

I have component:

 

<DirectoryRef Id="Directory.Core.Pages.Include">

    <Component Id="Component.Include"
Guid="99983D32-636A-47FE-BC10-E20C5E7C1968">

        <CreateFolder/>

 

        <File Id="File.Include.Footer.html" Name="Footer.html"
Source="$(var.BinDir)Include\Footer.html"></File>

        <File Id="File.Include.Header.html" Name="Header.html"
Source="$(var.BinDir)Include\Header.html"></File>

        <File Id="File.Include.InnerPageFooter.html"
Name="InnerPageFooter.html"
Source="$(var.BinDir)Include\InnerPageFooter.html"></File>

        <File Id="File.Include.InnerPageHeader.html"
Name="InnerPageHeader.html"
Source="$(var.BinDir)Include\InnerPageHeader.html"></File>

    </Component>

</DirectoryRef>

 

Now when I try to create patch in next version, I've changed the
InnerPageHeader.html file. During patch creation I've received the
warning
that InnerPageHeader.html is changed but Footer.html which is KeyPath
wasn't
changed. This file will not be patched on the target system if the
REINSTALLMODE does not contain 'A'. The KeyPath file should also be
changed
and included in your patch.

 

But I don't need to change Footer.html.

 

I've tried to add registry entry for each component and use it as
KeyPath:

 

<DirectoryRef Id="Directory.Core.Pages.Include">

    <Component Id="Component.Include"
Guid="99983D32-636A-47FE-BC10-E20C5E7C1968">

        <CreateFolder/>

 

        <RegistryValue Root="HKLM"
Key="Software\$(var.Manufacturer)\$(var.ProductClass)\Components\99983D3
2-63
6A-47FE-BC10-E20C5E7C1968" Type="string" Value="$(var.ProductVersion)"
KeyPath="yes" />

 

        <File Id="File.Include.Footer.html" Name="Footer.html"
Source="$(var.BinDir)Include\Footer.html"></File>

        <File Id="File.Include.Header.html" Name="Header.html"
Source="$(var.BinDir)Include\Header.html"></File>

        <File Id="File.Include.InnerPageFooter.html"
Name="InnerPageFooter.html"
Source="$(var.BinDir)Include\InnerPageFooter.html"></File>

        <File Id="File.Include.InnerPageHeader.html"
Name="InnerPageHeader.html"
Source="$(var.BinDir)Include\InnerPageHeader.html"></File>

    </Component>

</DirectoryRef>

 

Since value of registry entry is $(var.ProductVersion), which I will
change
on each next build, I've assumed that in this case I will have changed
keypath entry on each build and will pass the warning described above.

 

But (I don't know why) in this case I've received the same warning about
registry entry:

 

Warning     21

File 'File.Include.InnerPageHeader.html' in Component
'Component.Include'
was changed, but the KeyPath file 'reg25467E6DA6AD8545CE0253E2C2F3C454'
was
not. This file will not be patched on the target system if the
REINSTALLMODE
does not contain 'A'. The KeyPath file should also be changed and
included
in your patch.

 

 

Any suggestions?

 

Thanks

 

 

------------------------------------------------------------------------
------
Start uncovering the many advantages of virtual appliances
and start using them to simplify application deployment and
accelerate your shift to cloud computing.
http://p.sf.net/sfu/novell-sfdev2dev
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users

------------------------------------------------------------------------------
Start uncovering the many advantages of virtual appliances
and start using them to simplify application deployment and
accelerate your shift to cloud computing.
http://p.sf.net/sfu/novell-sfdev2dev
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users

Reply via email to