I am still getting the following with your recommended changes:- G:\WiX3\ACT Network Sync\ACT Network Sync\Product.wxs(19,0): error LGHT0204: ICE64: The directory CommonAppDataFolder is in the user profile but is not listed in the RemoveFile table.
I am creating a folder under commonappdatafolder. I don't know why this error is coming up. //////////////////////////////////////////////////////////////////////////// //////code//////////////// <?foreach directory in PersonalDir1;CommonAppDir1?> <?if $(var.directory) = "CommonAppDir1"?> <?define condition = "ALLUSERS"?> <?define compVar="ALLUSERSCOMP"?> <?else?> <?define condition = "NOT ALLUSERS"?> <?define compVar="NOTALLUSERSCOMP"?> <?endif?> <Component Id="Act.Data.$(var.compVar).dll3" Directory="$(var.directory)" Guid="*" Feature="ProductFeature"> <Condition>$(var.condition)</Condition> <File Id="Act.Data.$(var.compVar).dll3" Name="Act.Data.dll3" Source="G:\cvsroot\Mercury\bin\Act.Data.dll" DiskId="1" KeyPath="yes" /> <RemoveFolder Id="Act.Data.$(var.compVar).dll3" On="uninstall"/> </Component> //////////////////////////////////////////////////////////////////////////// ////////////////////// -----Original Message----- From: Blair [mailto:os...@live.com] Sent: Friday, August 21, 2009 2:06 PM To: 'General discussion for Windows Installer XML toolset.' Subject: Re: [WiX-users] How to work with ALLUSERS These errors are all ICE errors. Here is one way: For errors 3, 4, & 5 (the ICE64s): In each component, add <RemoveFolder Id="copy-the-component-Id-value-here" On="uninstall"/> to each component. You could have added the attribute Feature="ProductFeature" instead of having to create the ComponentRef elements inside the feature. I mentioned that already. Regarding ICE38 (errors 1 & 2): In the case of "real" per-user directories, this is valid, although it only works for "self-heal" scenarios (and uninstall doesn't clean them except for the current user). In the case of CommonAppDataFolder it is a per-machine location (the ICE is simply programmed incorrectly, aka a bug). Since you are installing per-user in the "real" user profile case, and you are installing per-machine in the case of writing to the supposed per-profile CommonAppDataFolder directory (which doesn't change based on the user), I would personally suppress ICE38 in my build, and evaluate all ICE38 reports (using smoke and/or Orca) as part of my QA/QC/test approval process to ensure that every report falls into the above categories (i.e. there is NO case where a per-machine installation will install into a real per-user location). In Votive, you suppress ICE38 by right-clicking the wix project and selecting Properties, selecting the Tool Settings tab in the form that opens in the editor, and adding ICE38 in the "Suppress specific ICE validation:" box (it needs to include the "ICE" part, not just the numbers). If not using the Visual Studio IDE, add <SuppressIces>ICE38</SuppressIces> (or append ;ICE38 to the property you already have) to one of your non-conditioned <PropertyGroup> elements in your .wixproj file. Before you suppress ICE38 (or any other ICE), please search ICE38 and educate yourself as much as you can on this particular test and any reasoning you can find about it and how it relates to your scenario. The issues this tests raises is one of the reasons that applications should be built in such a way as to prevent per-machine installations from EVER installing or requiring preinstalled ANY per-user data of any form (it should always create/copy it itself). It also illustrates one of the several problems with creating installers that can be switched between per-user and per-machine (including the fact that UAC basically breaks your installation experience on Vista). -----Original Message----- From: Hotmail Acc [mailto:rpat...@hotmail.com] Sent: Friday, August 21, 2009 9:38 AM To: 'General discussion for Windows Installer XML toolset.' Subject: Re: [WiX-users] How to work with ALLUSERS I did some this like this and getting the following errors:- For Errors 1, 2 how can I avoid adding unnecessary keys to registry. Since I will be adding lot of files under these folders. I was noticing Errors similar to 3,4,5 if I don't put components under DirectoryRef. How do I get rid of these errors in my dynamic scenario. Also, I had to add both the component ID's to feature list(Act.Data.ALLUSERSCOMP.dll3, Act.Data.NOTALLUSERSCOMP.dll3). ============================================================================ == 1)G:\WiX3\ACT Network Sync\ACT Network Sync\Product.wxs(157,0): error LGHT0204: ICE38: Component Act.Data.NOTALLUSERSCOMP.dll3 installs to user profile. It must use a registry key under HKCU as its KeyPath, not a file. 2)G:\WiX3\ACT Network Sync\ACT Network Sync\Product.wxs(157,0): error LGHT0204: ICE38: Component Act.Data.ALLUSERSCOMP.dll3 installs to user profile. It must use a registry key under HKCU as its KeyPath, not a file. 3)G:\WiX3\ACT Network Sync\ACT Network Sync\Product.wxs(23,0): error LGHT0204: ICE64: The directory PersonalDir1 is in the user profile but is not listed in the RemoveFile table. 4)G:\WiX3\ACT Network Sync\ACT Network Sync\Product.wxs(20,0): error LGHT0204: ICE64: The directory CommonAppDir1 is in the user profile but is not listed in the RemoveFile table. 5)G:\WiX3\ACT Network Sync\ACT Network Sync\Product.wxs(19,0): error LGHT0204: ICE64: The directory CommonAppDataFolder is in the user profile but is not listed in the RemoveFile table. ============================================================================ == ==============================================code snippets below============= ...... <Directory Id="DesktopFolder" Name="DesktopFolder"/> <Directory Id="StartMenuFolder" Name="StartMenuFolder"/> <Directory Id="ProgramMenuFolder" Name="ProgramMenuFolder"> <Directory Id="ApplicationProgramsFolder" Name="ACT! Network Sync"/> <Directory Id="CommonAppDataFolder"> <Directory Id="CommonAppDir1" Name="ACT"/> </Directory> <Directory Id="PersonalFolder"> <Directory Id="PersonalDir1" Name="ACT"/> </Directory> </Directory> </Directory> ....... <?foreach directory in PersonalDir1;CommonAppDir1?> <?if $(var.directory) = "CommonAppDir1"?> <?define condition = "ALLUSERS"?> <?define compVar="ALLUSERSCOMP"?> <?else?> <?define condition = "NOT ALLUSERS"?> <?define compVar="NOTALLUSERSCOMP"?> <?endif?> <Component Id="Act.Data.$(var.compVar).dll3" Directory="$(var.directory)" Guid="*"> <Condition>$(var.condition)</Condition> <File Id="Act.Data.$(var.compVar).dll3" Name="Act.Data.dll3" Source="G:\cvsroot\Mercury\bin\Act.Data.dll" DiskId="1" KeyPath="yes" /> </Component> <?undef condition?> <?undef compVar?> <?endforeach?> ...... <Feature Id="ProductFeature" Title="ACT! Network Sync" Description="ACT! Network Sync Installation" Level="1" Display="expand" ConfigurableDirectory="INSTALLDIR"> ....... <ComponentRef Id="Act.Data.ALLUSERSCOMP.dll3" /> <ComponentRef Id="Act.Data.NOTALLUSERSCOMP.dll3" /> </Feature> ........ G:\WiX3\ACT Network Sync\ACT Network Sync\Product.wxs(157,0): error LGHT0204: ICE38: Component Act.Data.NOTALLUSERSCOMP.dll3 installs to user profile. It must use a registry key under HKCU as its KeyPath, not a file. G:\WiX3\ACT Network Sync\ACT Network Sync\Product.wxs(157,0): error LGHT0204: ICE38: Component Act.Data.ALLUSERSCOMP.dll3 installs to user profile. It must use a registry key under HKCU as its KeyPath, not a file. G:\WiX3\ACT Network Sync\ACT Network Sync\Product.wxs(23,0): error LGHT0204: ICE64: The directory PersonalDir1 is in the user profile but is not listed in the RemoveFile table. G:\WiX3\ACT Network Sync\ACT Network Sync\Product.wxs(20,0): error LGHT0204: ICE64: The directory CommonAppDir1 is in the user profile but is not listed in the RemoveFile table. G:\WiX3\ACT Network Sync\ACT Network Sync\Product.wxs(19,0): error LGHT0204: ICE64: The directory CommonAppDataFolder is in the user profile but is not listed in the RemoveFile table. -----Original Message----- From: Blair [mailto:os...@live.com] Sent: Thursday, August 20, 2009 4:46 PM To: 'General discussion for Windows Installer XML toolset.' Subject: Re: [WiX-users] How to work with ALLUSERS Dictionary, directory, both are in my email client's spell-check. Sorry. And yes, you should modify the File/@Id values the same way as the Component/@Id values. If you don't change the directory paths (or if you do, it is because you really are changing directories) and you don't alter the file names or change which files are keypaths of which components, the auto-generated component guids are quite stable (we never had any problems with any of the auto-generated guids we ever employed). In fact, autogenerating your component guids is a best-practice (as long as you live by the constraint of not messing with your directory tree all the time). Non-auto-generated random guids would be problematic. With regard to your earlier mention of features, you can use the Feature attribute of the Component element to hook your components into your features. You just need to make sure your fragment is already linked in so the block doesn't get left out. -----Original Message----- From: Hotmail Acc [mailto:rpat...@hotmail.com] Sent: Thursday, August 20, 2009 3:14 PM To: 'General discussion for Windows Installer XML toolset.' Subject: Re: [WiX-users] How to work with ALLUSERS I am still getting the following errors:- G:\WiX3\ACT Network Sync\ACT Network Sync\Product.wxs(157,0): error LGHT0091: Duplicate symbol 'File:Act.Data.dll3' found. G:\WiX3\ACT Network Sync\ACT Network Sync\Product.wxs(157,0): error LGHT0092: Location of symbol related to previous error. <?foreach directory in PersonalDir1;CommonAppDir1?> <?if $(var.directory) = "CommonAppDir1"?> <?define condition = "ALLUSERS"?> <?else?> <?define condition = "NOT ALLUSERS"?> <?endif?> <Component Id="Act.Data.$(var.directory).dll3" Directory="$(var.directory)" Guid="*"> <Condition>$(var.condition)</Condition> <File Id="Act.Data.dll3" Name="Act.Data.dll3" Source="G:\cvsroot\Mercury\bin\Act.Data.dll" DiskId="1" KeyPath="yes" /> </Component> <?undef condition?> <?endforeach?> If I select random guids won't it be a problem during minor upgrades? Minor upgrade might think that the component is deleted if we generate a new guid for this component during patch build. Also, In you code below you have used $(var.dictionary). Is "dictionary" a typo? -----Original Message----- From: Blair [mailto:os...@live.com] Sent: Thursday, August 20, 2009 2:19 PM To: 'General discussion for Windows Installer XML toolset.' Subject: Re: [WiX-users] How to work with ALLUSERS No, with the Directory attribute set you don't need the Components inside a DirectoryRef. You do need to make the Ids and guids unique, however. I suggest the guids are '*' and the ids incorporate $(var.directory) (or anything else you are willing to define that you will vary). <?foreach directory in PersonalDir1;CommonAppDir1?> <?if $(var.directory) = "CommonAppDir1"?> <?define condition = "ALLUSERS"?> <?else?> <?define condition = "NOT ALLUSERS"?> <?endif?> <Component Id="Act.Data.$(var.dictionary).dll3" Directory="$(var.directory)" Guid="*"> <Condition>$(var.condition)</Condition> <File Id="Act.Data.dll3" Name="Act.Data.dll" Source="G:\xxx\Act.Data.dll" DiskId="1" KeyPath="yes" /> </Component> <?undef condition?> <?endforeach?> -----Original Message----- From: Hotmail Acc [mailto:rpat...@hotmail.com] Sent: Thursday, August 20, 2009 2:00 PM To: 'General discussion for Windows Installer XML toolset.' Subject: Re: [WiX-users] How to work with ALLUSERS Need some help to debug this:- Question :----Do I have to put the "foreach" block into some directoryRef? If so how do I do it(since directory ref could be CommonAppDir1 or PersonalDir1). Also, this foreach section is not added into <Feature></Feature> block. I got the following errors when compiled. Error:- G:\WiX3\ACT Network Sync\ACT Network Sync\Product.wxs(155,0): error LGHT0091: Duplicate symbol 'Component:Act.Data.dll3' found. G:\WiX3\ACT Network Sync\ACT Network Sync\Product.wxs(155,0): error LGHT0092: Location of symbol related to previous error. G:\WiX3\ACT Network Sync\ACT Network Sync\Product.wxs(157,0): error LGHT0091: Duplicate symbol 'File:Act.Data.dll3' found. G:\WiX3\ACT Network Sync\ACT Network Sync\Product.wxs(157,0): error LGHT0092: Location of symbol related to previous error. File :- Product.wxs ..... ..... <Directory Id="TARGETDIR" Name="SourceDir"> <Directory Id="ProgramFilesFolder"> <Directory Id="NewDirectory1" Name="ACT"> <Directory Id="NewDirectory2" Name="ACT for Windows"> <Directory Id="INSTALLDIR" Name="ACT Network Sync"> </Directory> </Directory> </Directory> </Directory> <Directory Id="DesktopFolder" Name="DesktopFolder"/> <Directory Id="StartMenuFolder" Name="StartMenuFolder"/> <Directory Id="ProgramMenuFolder" Name="ProgramMenuFolder"> <Directory Id="ApplicationProgramsFolder" Name="ACT! Network Sync"/> <Directory Id="CommonAppDataFolder"> <Directory Id="CommonAppDir1" Name="ACT"/> </Directory> <Directory Id="PersonalFolder"> <Directory Id="PersonalDir1" Name="ACT"/> </Directory> </Directory> </Directory> ..... <DirectoryRef Id="INSTALLDIR"> ..... </DirectoryRef> ..... ..... <?foreach directory in PersonalDir1;CommonAppDir1?> <?if $(var.directory) = "CommonAppDir1"?> <?define condition = "ALLUSERS"?> <?else?> <?define condition = "NOT ALLUSERS"?> <?endif?> <Component Id="Act.Data.dll3" Directory="$(var.directory)" Guid="{xxxxxxxxxxxx}"> <Condition>$(var.condition)</Condition> <File Id="Act.Data.dll3" Name="Act.Data.dll" Source="G:\xxx\Act.Data.dll" DiskId="1" KeyPath="yes" /> </Component> <?undef condition?> <?endforeach?> ..... ..... -----Original Message----- From: Blair [mailto:os...@live.com] Sent: Thursday, August 20, 2009 10:23 AM To: 'General discussion for Windows Installer XML toolset.' Subject: Re: [WiX-users] How to work with ALLUSERS The most reliable way would be to duplicate the components installing the files and condition them (one set uses "ALLUSERS" and the other set uses "NOT ALLUSERS"). You may be able to use the preprocessor's foreach to avoid duplicating the source code (note, I have not tested this): <DirectoryRef Id="INSTALLDIR"> <Directory Id="CommonAppDataFolder"/> <Directory Id="PersonalFolder"/> </DirectoryRef> <?foreach directory in PersonalFolder;CommonAppDataFolder?> <?if $(var.directory) = "CommonAppDataFolder"?> <?define condition = "ALLUSERS"?> <?else?> <?define condition = "NOT ALLUSERS"?> <?endif?> <Component Id=... Directory="$(var.directory)"> <Condition>$(var.condition)</Condition> <File .../> ... </Component> ... <?undef condition?> <?endforeach?> -----Original Message----- From: Hotmail Acc [mailto:rpat...@hotmail.com] Sent: Thursday, August 20, 2009 8:56 AM To: 'General discussion for Windows Installer XML toolset.' Subject: [WiX-users] How to work with ALLUSERS I need a sample wxs file which can install files to different location based on the value of ALLUSERS. Example:- allusers=1, some selected files will be installed to commonappdata folder(C:\Documents and Settings\All Users\Application Data). allusers={}, the above files will be installed to personal folder (C:\Documents and Settings\Administrator\My Documents). I have created a dialog where user can select the value for ALLUSERS. My next goal is to copy some files to different locations based on the ALLUSERS value. Thanks, Ravi ---------------------------------------------------------------------------- -- Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day trial. Simplify your report design, integration and deployment - and focus on what you do best, core application coding. Discover what's new with Crystal Reports now. http://p.sf.net/sfu/bobj-july _______________________________________________ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users ---------------------------------------------------------------------------- -- Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day trial. Simplify your report design, integration and deployment - and focus on what you do best, core application coding. Discover what's new with Crystal Reports now. http://p.sf.net/sfu/bobj-july _______________________________________________ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users ---------------------------------------------------------------------------- -- Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day trial. Simplify your report design, integration and deployment - and focus on what you do best, core application coding. Discover what's new with Crystal Reports now. http://p.sf.net/sfu/bobj-july _______________________________________________ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users ---------------------------------------------------------------------------- -- Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day trial. Simplify your report design, integration and deployment - and focus on what you do best, core application coding. Discover what's new with Crystal Reports now. http://p.sf.net/sfu/bobj-july _______________________________________________ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users ---------------------------------------------------------------------------- -- Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day trial. Simplify your report design, integration and deployment - and focus on what you do best, core application coding. Discover what's new with Crystal Reports now. http://p.sf.net/sfu/bobj-july _______________________________________________ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users ---------------------------------------------------------------------------- -- Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day trial. Simplify your report design, integration and deployment - and focus on what you do best, core application coding. Discover what's new with Crystal Reports now. http://p.sf.net/sfu/bobj-july _______________________________________________ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users ---------------------------------------------------------------------------- -- Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day trial. Simplify your report design, integration and deployment - and focus on what you do best, core application coding. Discover what's new with Crystal Reports now. http://p.sf.net/sfu/bobj-july _______________________________________________ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users ---------------------------------------------------------------------------- -- Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day trial. Simplify your report design, integration and deployment - and focus on what you do best, core application coding. Discover what's new with Crystal Reports now. http://p.sf.net/sfu/bobj-july _______________________________________________ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users ------------------------------------------------------------------------------ Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day trial. Simplify your report design, integration and deployment - and focus on what you do best, core application coding. Discover what's new with Crystal Reports now. http://p.sf.net/sfu/bobj-july _______________________________________________ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users