title: Referencing ProgramFiles folder in WixProj Bootstrapper
body: <p>(I've looked at other answers to no avail).</p>
  
  <p>In my WixProj file, I have a few bootstrapper calls referencing necessary files.</p>
  
  <pre><code>&lt;GenerateBootstrapper ApplicationFile="$(TargetFileName)" ApplicationName="Case Tracking" BootstrapperItems="@(BootstrapperFile)" ComponentsLocation="HomeSite" CopyComponents="False" OutputPath="$(OutputPath)" Path="$(env.ProgramFiles)\Microsoft SDKs\Windows\v8.1A\BootStrapper" ApplicationRequiresElevation="True" Culture="en-US" Condition=" '$(Configuration)|$(Platform)' == 'Debug|x86' " /&gt;
  &lt;GenerateBootstrapper ApplicationFile="$(TargetFileName)" ApplicationName="Case Tracking" BootstrapperItems="@(BootstrapperFile)" ComponentsLocation="HomeSite" CopyComponents="False" OutputPath="$(OutputPath)" Path="$(env.ProgramFiles)\Microsoft SDKs\Windows\v7.0A\BootStrapper" ApplicationRequiresElevation="True" Culture="en-US" Condition=" '$(Configuration)|$(Platform)' == 'Debug Web|x86' " /&gt;
  &lt;GenerateBootstrapper ApplicationFile="$(TargetFileName)" ApplicationName="Case Tracking" BootstrapperItems="@(BootstrapperFile)" ComponentsLocation="HomeSite" CopyComponents="False" OutputPath="$(OutputPath)" Path="$(env.ProgramFiles)\Microsoft SDKs\Windows\v6.0A\BootStrapper" ApplicationRequiresElevation="True" Culture="en-US" Condition=" '$(Configuration)|$(Platform)' == 'Release|x86' " /&gt;
  </code></pre>
  
  <p>The problem with the above code is that when it attempts to build, I get the error</p>
  
  <p>The expression """.ProgramFiles" cannot be evaluated. Method 'System.String.ProgramFiles' not found.</p>
  
  <p>So how can I reference the ProgramFiles environment within the WixProj file?</p>
  
  <p>The Project builds properly locally - it just won't build properly through MSBuild.</p>
  
  <p>Thanks</p>