title: How to install application in custom folder using wix installer,other than Program Files folder
body: <p>I have created an installer using wix. By default the application gets installed under Program Files folder.I need to create a folder for my application under <code>c:</code> directory and install my application inside there.</p>
  
  <pre><code>&lt;Fragment&gt;
        &lt;Directory Id="TARGETDIR" Name="SourceDir"&gt;
    &lt;Directory Id="WINDOWSVOLUME" &gt;
      &lt;Directory Id="INSTALLLOCATION" Name="WIXDemoApp"&gt;
      &lt;/Directory&gt;
    &lt;/Directory&gt;
  &lt;/Directory&gt;
  
  &lt;SetDirectory Id="WINDOWSVOLUME" Value="c"/&gt;
  </code></pre>
  
  <p></p>
  
  <pre><code>&lt;Fragment&gt;
      &lt;ComponentGroup Id="ProductComponents" Directory="INSTALLFOLDER"&gt;
  
          &lt;!-- TODO: Remove the comments around this Component element and the ComponentRef below in order to add resources to this installer. --&gt;
           &lt;Component Id="MyApplication.exe"&gt;
       &lt;File Source="$(var.MyApplication.TargetPath)" Name="MyApp.exe" Id="MYAPPEXE" KeyPath="yes"  /&gt;
              &lt;!-- TODO: Insert files, registry keys, and other resources here. --&gt;
           &lt;/Component&gt; 
      &lt;/ComponentGroup&gt;
  &lt;/Fragment&gt;
  </code></pre>
  
  <p>I am getting the following error "<code>error LGHT0094: Unresolved reference to symbol 'Directory:INSTALLFOLDER' in section 'Fragment:'</code>".</p>
  
  <p><strong>Update:</strong></p>
  
  <pre><code>&lt;Fragment&gt;
            &lt;Directory Id="TARGETDIR" Name="SourceDir"&gt;
        &lt;Directory Id="WindowsVolume" &gt;
          &lt;Directory Id="INSTALLLOCATION" Name="WIXDemoApp"&gt;
          &lt;/Directory&gt;
        &lt;/Directory&gt;
      &lt;/Directory&gt;
  
      &lt;SetDirectory Id="WindowsVolume" Value="c"/&gt;
    &lt;/Fragment&gt;
  
      &lt;Fragment&gt;
          &lt;ComponentGroup Id="ProductComponents" Directory="INSTALLLOCATION"&gt;
  
              &lt;!-- TODO: Remove the comments around this Component element and the ComponentRef below in order to add resources to this installer. --&gt;
               &lt;Component Id="MyApplication.exe"&gt;
           &lt;File Source="$(var.MyApplication.TargetPath)" Name="MyApp.exe" Id="MYAPPEXE" KeyPath="yes"  /&gt;
                  &lt;!-- TODO: Insert files, registry keys, and other resources here. --&gt;
               &lt;/Component&gt; 
          &lt;/ComponentGroup&gt;
      &lt;/Fragment&gt;
  </code></pre>
  
  <p>This is giving me another error <code>"error LGHT0204: ICE99: The directory name: WindowsVolume is the same as one of the MSI Public Properties and can cause unforeseen side effects.</code>".Googled and refereed <a href="http://windows-installer-xml-wix-toolset.687559.n2.nabble.com/Error-using-WindowsVolume-predefined-folder-td3313078.html" rel="noreferrer">this</a>  and <a href="https://www.mail-archive.com/wix-users@lists.sourceforge.net/msg05670.html" rel="noreferrer">this</a> to fix this.But not working for me,still i am getting the same error as "error LGHT0204: ICE99: The directory name: WindowsVolume is the same as one of the MSI Public Properties and can cause unforeseen side effects.".Any idea what would be the problem.</p>