title: WIX Writing user data into config file
body: <p>I would like to ask a WiX installer question. I created a working installer that does many things already. I still need to ask the user for some specific information (the GUI is already done), and write it into a config file.</p>
  
  <p>From this snippet, I think I could use the <code>INSTALLFOLDER</code> global variable.</p>
  
  <pre><code>&lt;Directory Id="TARGETDIR" Name="SourceDir"&gt;
    &lt;Directory Id="IISROOT" Name='WebDir'&gt;
      &lt;Directory Id="INSTALLFOLDER" Name="IVRDesigner"&gt;
      &lt;/Directory&gt;
    &lt;/Directory&gt;
  &lt;/Directory&gt;
  </code></pre>
  
  <p>This is the part, when I want to use that. This code is taken from a tutorial, should work well, if the source tag is filled properly. The <code>..\src\Web.config</code> is just a dummy, so the code can compile. The default installed path for the <code>web.config</code> file will be <code>C:\inetpub\wwwroot\myfolder</code>, but the user can change this during the installation. </p>
  
  <p>The question is: how could I use the global variable here, or what kind of solution, do you recommend? </p>
  
  <p>Thanks in advance.</p>
  
  <pre><code>&lt;Component Id="ConfigureWebConfig" Guid="*"&gt;
      &lt;File Id="Web.config" Name="MyConfigfile" Vital="yes" KeyPath="yes" 
            Source="..\src\Web.config" /&gt;
      &lt;util:XmlFile Id="AppConfigSetConnStr" Action="setValue" 
           Permanent="yes" File="[#Web.config]"
           ElementPath="/configuration/connectionStrings/add[\[]@name='GeoIVRDesignerEntities'[\]]" Name="connectionString"
           Value="data source=[DBSERVER];" /&gt;
    &lt;/Component&gt;
  </code></pre>