title: Update app.config from WIX setup?
body: <p>I am trying Wix 3.6 and this is how it looks right now : </p>
  
  <pre><code>&lt;?xml version="1.0" encoding="UTF-8"?&gt;
  </code></pre>
  
  <p>
      
          </p>
  
  <pre><code>&lt;Directory Id="TARGETDIR" Name="SourceDir"&gt;
      &lt;Directory Id="myappINSTALLDIR" Name="myapp5Service"&gt;
          &lt;Component Id="SampleServiceComponent" DiskId="1" Guid="6f51c0f3-776c-4aec-a200-1f199352c6c3" Win64="yes"&gt;
            &lt;File Id="myapp5.WindowsService.exe" Name="myapp5.WindowsService.exe" Source="$(var.myapp.WindowsService.TargetDir)\myapp5.WindowsService.exe" KeyPath='yes'/&gt;
            ...
  
            &lt;ServiceInstall Id="InstallmyappService" DisplayName="myappService" Name="myapp5.WindowsService.exe" Description="myapp 5 Service - För effektivare och enklare operationsplanering" Account="LocalSystem" ErrorControl="normal" Start="auto" Type="ownProcess" Vital="yes" /&gt;
            &lt;ServiceControl Id="ControlmyappService" Name="myapp5.WindowsService.exe" Start="install" Stop="both" Remove="uninstall" Wait="yes" /&gt;
          &lt;/Component&gt;
      &lt;/Directory&gt;
  &lt;/Directory&gt;
  
  
  &lt;WixVariable Id="WixUIBannerBmp" Value="$(var.ProjectDir)\Image\myappTopBanner.bmp" /&gt;
  &lt;WixVariable Id="WixUIDialogBmp" Value="$(var.ProjectDir)\Image\myappDialogBackground.bmp" /&gt;
  
  &lt;Property Id="WIXUI_INSTALLDIR" Value="myappINSTALLDIR" /&gt;
  &lt;UIRef Id="WixUI_InstallDir" /&gt;
  
  &lt;Feature Id="ProductFeature" Title="Wix_myapp.WindowsService" Level="1"&gt;
    &lt;ComponentRef Id="SampleServiceComponent" /&gt;
  &lt;/Feature&gt;
  &lt;Media Id="1" Cabinet="SampleServiceComponent.cab" EmbedCab="yes" /&gt;
  &lt;/Product&gt;
  </code></pre>
  
  <p></p>
  
  <p>Now I need to add a dialog to the Wix setup where one appSetting and one baseadress(WCF) is set to the app.config. This most be done before the installation becouse it will decide the name of the Windows Service that the Wix is installning.</p>
  
  <p>And exampel would be great!</p>
  
  <p>Edit 1: </p>
  
  <pre><code>    &lt;WixVariable Id="WixUIBannerBmp" Value="$(var.ProjectDir)\Image\myappTopBanner.bmp" /&gt;
  &lt;WixVariable Id="WixUIDialogBmp" Value="$(var.ProjectDir)\Image\myappDialogBackground.bmp" /&gt;
  
  &lt;Property Id="SERVICEADDRESS" Value="http://serviceaddress"/&gt;
  &lt;Property Id="WIXUI_INSTALLDIR" Value="myappINSTALLDIR" /&gt;
  &lt;UIRef Id="WixUI_InstallDir" /&gt;
  
  &lt;util:XmlFile Id="UpdateBaseAddress"
    Action="setValue"
    File="$(var.myapp.WindowsService.TargetDir)\myapp5.WindowsService.exe.config"
    SelectionLanguage="XPath"
    Permanent="yes"
    ElementPath="/configuration/applicationSettings/ServiceName"
    Name="baseAddress" Value="[SERVICEADDRESS]" /&gt;
  
  &lt;Feature Id="ProductFeature" Title="Wix_myapp.WindowsService" Level="1"&gt;
    &lt;ComponentRef Id="SampleServiceComponent" /&gt;
  &lt;/Feature&gt;
  &lt;Media Id="1" Cabinet="SampleServiceComponent.cab" EmbedCab="yes" /&gt;
  &lt;/Product&gt;
  </code></pre>
  
  <p></p>