Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: wix Modules
Hi,
 
I have 4 services merge modules... I have created a "Shared services merge module" that has 4 files that are required to be installed with each service (so I have 5 merge modules, 1 is shared between the other 4) The 4 services are installed to a unique directory i.e.:
C:\program files\company\product\services
Service1
Service2
Service3
Service4
and that shared merge module needs to install into each ServiceX directory...
 
I am running into problems trying to install that shared merge module here is some code:
 
<Feature Id="Feature_1" Title="Main Feature" Description="This will installl the 1 Feature..." Level="1" Display="expand" ConfigurableDirectory="INSTALLFOLDER">
      <MergeRef Id="feature1mainmergemodule"/>
      <MergeRef Id="feature1mainmergemodule1"/>
      <MergeRef Id="FirstServicesMergeModule"/>
      <MergeRef Id="SecondtServicesMergeModule"/>
      <MergeRef Id="ThirdServicesMergeModule"/>
      <MergeRef Id="FourthServicesMergeModule"/>
      <MergeRef Id="SharedServicesMergeModule"/>
      </Feature>
 
          <Feature Id="Feature_2" Title="Main Feature" Description="This will installl the 2 Feature..." Level="1" Display="expand" ConfigurableDirectory="INSTALLFOLDER">
      <MergeRef Id="feature2mainmergemodule"/>
      <MergeRef Id="feature2mainmergemodule1"/>
      <MergeRef Id="FirstServicesMergeModule"/>
      <MergeRef Id="SecondtServicesMergeModule"/>
      <MergeRef Id="ThirdServicesMergeModule"/>
      <MergeRef Id="FourthServicesMergeModule"/>
      <MergeRef Id="SharedServicesMergeModule"/>
      </Feature>
 
I have a fragments for each service (so 4 in total for the services) so the SharedServicesMergeModule mrege module is referenced 4 times in each of the fragments, i.e.:
 

        <Fragment>
    <Directory Id="TARGETDIR" Name="SourceDir">
      <Directory Id="ProgramFilesFolder">
        <Directory Id="ProgramFilesFolder.MyCompany" Name="Company">
          <Directory Id="ProgramFilesFolder.MyProduct" Name="Product">
            <Directory Id="ProgramFilesFolder.Services" Name="Services">
              <Directory Id="ProgramFilesFolder.ServiceName" Name="Service1">
                <Merge Id="FirstServicesMergeModule" DiskId="1" SourceFile="..\Services\FirstServicesMergeModule\bin\$(var.Configuration)\FirstServicesMergeModule.msm" Language="1033"/>
                <Merge Id="SharedServicesMergeModule" DiskId="1" SourceFile="..\Services\SharedServicesMergeModule\bin\$(var.Configuration)\SharedServicesMergeModule.msm" Language="1033"/>
              </Directory>
            </Directory>
          </Directory>
        </Directory>
      </Directory>
    </Directory>
  </Fragment>
 
  Secondservice, thirdservice, fourthservice...
 
However when I compile the setup product wix I get these errors:
 
  Error 12  The merge module 'SharedServicesMergeModule' contains a file identifier, 'File_ServiceAssembly.2FC299CF_7F63_460C_B60D_8F7C3FF8C3C7', that is duplicated either in another merge module or in a File/@Id attribute.  File identifiers must be unique.  Please change one of the file identifiers to a different value.  C:\Dev\Setup\Product.wxs    107 1   Setup
 
So my question is... How can a share 1 merge module with the four services merge module?
 
thanks,
 
Steve
Posted 31-Aug-12 5:29am
Edited 31-Aug-12 9:55am
(no name)231.1K
v2

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 OriginalGriff 7,903
1 Sergey Alexandrovich Kryukov 7,192
2 DamithSL 5,604
3 Manas Bhardwaj 4,986
4 Maciej Los 4,820


Advertise | Privacy | Mobile
Web01 | 2.8.1411023.1 | Last Updated 31 Aug 2012
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100