How can I get around "this component does not fit the criteria for having an automatically generated guid" How can I get around "this component does not fit the criteria for having an automatically generated guid" windows windows

How can I get around "this component does not fit the criteria for having an automatically generated guid"


All you need to do is set Directory/@ComponentGuidGenerationSeed and then you can use auto guids for non-standard folder.


I just got it...kind of annoying but its working alright...

I was modifying the TARGETDIR and working with it prior...but now, I realize that I can easily just have worked with INSTALLDIR...for example, I re-factored my directory structure as such:

<Directory Id='TARGETDIR' Name='SourceDir'>  ...  <Directory Id="ProgramFilesFolder">    <Directory Id="blahFolder" Name="blah">      <Directory Id="INSTALLFOLDER" Name="blah"/>    </Directory>  </Directory></Directory>

I can get components to reference the INSTALLFOLDER and it will auto-generate GUIDs for them:

<ComponentGroup Id='blahgroup'>    <Component Id='blahId' Directory='INSTALLFOLDER' Transitive='no'>      <RegistryKey Root='HKLM' Key='Software\blah\blah' ForceCreateOnInstall='no' ForceDeleteOnUninstall='no'>        <RegistryValue Type='string' Name='blah' Value='BLAH' />      </RegistryKey>    </Component>    ...</ComponentGroup>

But in my UI, its nice because I can modify just the installation folder path quite well:

<Product ...>  ...  <CustomAction Id='SetInstallFolder' Property='INSTALLFOLDER' Value='[ProgramFilesFolder]blah\blah\'/>  ...</Product>

I can then force the INSTALLFOLDER to point anywhere I want:

<InstallUISequence>  <Custom Action='SetInstallFolder' Sequence='1'/>  ...</InstallUISequence><AdminUISequence>  <Custom Action='SetInstallFolder' Sequence='1'/>  ...</AdminUISequence>