I have a large project with numerous sub-directories I need to harvest files from. I have this entry in my product.wxs file:
<Feature Id="DefaultFeature" Title="Main Feature" Level="1">
<ComponentGroupRef Id="APP_DATA" />
</Feature>
At build time I run a bat file with a number of heat commands to harvest this directory, among others :
"%WIX%\bin\heat" dir ".\image\App_Data" -cg APP_DATA -gg -scom -dr App_Data -gl -sfrag -srd -out ".\App_Data.wxs"
This generates a file App_Data.wxs in the same folder as the Product.wxs file. But when the build runs I get the following error :
Product.wxs(97): error LGHT0094: Unresolved reference to symbol 'WixComponentGroup:APP_DATA' in section 'Product:{FAD0EA15-49BC-4EF8-A440-87070E4FAC7A}'
I appears that the WiX project cannot find the "APP_DATA" component group in the file App_Data.wxs. How do I get it to do that? I would assume there is an entry in the ProjectName.wixproj file but I have not found what you do.
I have been searching the internet and found a thousand ways to set this up but none go into enough detail about how you get the WiX project to see files generated by heat during the build. I saw this post.
Which talks about editing the Target Name="BeforeBuild"
section of the wixproj file. Is that the only way to get this to work?