Technically speaking it might be possible to have a Condition on the Exe 
Component that operates independent of the Shortcut Component.  That would be 
silly if the Shortcut could point to something that didn't get installed.  The 
ICE can't really tell that (or, at least chooses not to)... so it decides it's 
better to warn you than to accept that you basically did the right thing and 
probably have nothing to worry about.

ICE errors almost always (bugs sometimes show up) are things to fix.  ICE 
warnings are things to investigate and if you are following the rules then it's 
all good.

-----Original Message-----
From: Colin Fox [mailto:greenene...@gmail.com]
Sent: Wednesday, January 28, 2009 11:07
To: wix-users
Subject: [WiX-users] Incomprehensible warning

I have an MSI file that seems to work perfectly and do exactly what I want.
However, I get two warnings when building it, both relating to shortcuts;
one for the desktop shortcut and one for the menu shortcut.

The warning is this:

c:\Users\colinf\Documents\RMWix\Product.wxs(76): warning LGHT1076: ICE69:
Mismatched component reference. Entry 'DesktopShortcut' of the Shortcut
table belongs to component 'DesktopShortcut'. However, the formatted string
in the column 'Target' references file 'MyProgramEXE' which belongs to
component 'ProductComponent'. Components are in the same feature.

Here is the DesktopFolder part:

   <Directory Id="DesktopFolder" Name="Desktop">
        <Component Id="DesktopShortcut" Guid="$(var.shortcutguid)">
            <Condition>INSTALLDESKTOPSHORTCUT</Condition>
            <RegistryKey Root="HKCU" Key="Mycompany\Myprogram"
Action="createAndRemoveOnUninstall">
            <RegistryValue Name="blah" Value="1" Type="integer"
KeyPath="yes"/>
            </RegistryKey>
            <Shortcut Id="DesktopShortcut" Directory="DesktopFolder"
Name="My Program"
             ShortName="ShrtName" Icon="icon.ico" Target="[#MyProgramEXE]"/>
        </Component>
        </Directory>

And my feature declaration:

    <Feature Id="ProductFeature" Title="MyProgram" Level="1">
        <ComponentRef Id="ProductComponent" />
        <ComponentGroupRef Id='ComponentGroup1' />
        <ComponentRef Id='DesktopShortcut'/>
        <ComponentRef Id='ApplicationShortcut'/>
    </Feature>

I don't understand what the problem is. The shortcut is *supposed* to point
to the program - why is it complaining? And why is it complaining that both
the shortcut and the exe are in the same feature? Obviously they need to be,
so what's with the warning?

--
Regards,
 cf
------------------------------------------------------------------------------
This SF.net email is sponsored by:
SourcForge Community
SourceForge wants to tell your story.
http://p.sf.net/sfu/sf-spreadtheword
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users


------------------------------------------------------------------------------
This SF.net email is sponsored by:
SourcForge Community
SourceForge wants to tell your story.
http://p.sf.net/sfu/sf-spreadtheword
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users

Reply via email to