OK, you misunderstood me, or I didn't explain it well.

What you need to do to satisfy the ICE is to add a RegistryKey to the
Component and set that as the KeyPath. Unfortunately you will have to do
this in the merge module that you're merging. If you can't fix the merge
module you'll need to suppress the warning message (somehow I missed that it
was a merge module in your previous message).

For the example below you would use something like:

<Directory Id="PersonalFolder" SourceName=".">
   <Directory Id="MyTemplates" Name="My Templates">
      <Component Id="MyTemplatesData"
Guid="F01395F7-665D-1548-C565-AB8376CD74F0">
         <RegistryValue Id="ConfigXmlKeyPath" Root="HKCU"
Key="Software\MyCompany\MyProduct" Name="Config.xml" Value="1" KeyPath="yes"
/>
         <File Id="Config.xml" Name="Config.xml"
Source="$(var.SourcePath)\Config.xml" />
         <RemoveFolder On="uninstall" />
      </Component>
   </Directory>
</Directory>

The RemoveFolder element satisfies the other ICE requirement, that a folder
created in the user's profile is removed on uninstall.

-- 
Mike Dimmick

-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Ward, Mike
(MED US)
Sent: 19 June 2007 15:34
To: wix-users@lists.sourceforge.net
Subject: [WiX-users] My Documents Folder


Yesterday I posted a question asking how to write to the "My Documents"
folder. Well after some experimentation I came up with this.

    <Property Id="MYDOCUMENTSFOLDER">
      <RegistrySearch Id="MyDocumentsSearch" Root="HKCU"
Type="directory" Name="Personal"

Key="Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell
Folders" />
    </Property>

    ...

      <Directory Id="MYDOCUMENTSFOLDER" SourceName="User's Personal Data
Folder">
        <Directory Id="MyTemplates" Name="My Templates">
          <Component Id="MyTemplatesData"
Guid="F01395F7-665D-1548-C565-AB8376CD74F0">
            <File Id="Config.xml" Name="Config.xml"
Source="$(var.SourcePath)\Config.xml" />
          </Component>
        </Directory>
      </Directory>

This compiles and runs without warning. Is this considered the correct
method?

Regards,

Mike

----------------------------------------------------------------------------
This message and any included attachments are from Siemens Medical Solutions
and are intended only for the addressee(s).
The information contained herein may include trade secrets or privileged or
otherwise confidential information. Unauthorized review, forwarding,
printing,
copying, distributing, or using such information is strictly prohibited and
may
be unlawful. If you received this message in error, or have reason to
believe
you are not authorized to receive it, please promptly delete this message
and
notify the sender by e-mail with a copy to
[EMAIL PROTECTED]

Thank you

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users


-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users

Reply via email to