1

I'm trying to make a wix installer. for a web application.

the following is my wsx file

<?xml version="1.0" encoding="UTF-8"?>
<Wix xmlns="http://wixtoolset.org/schemas/v4/wxs">
  <Product Id="Guid" Name="TestInstaller" Language="1033" Version="1.0.0.0" Manufacturer="Companyname" UpgradeCode="Guid1">
    <Package InstallerVersion="200" Compressed="yes" InstallScope="perMachine" Platform="x64" />

    <MajorUpgrade DowngradeErrorMessage="A newer version of [ProductName] is already installed." />
    <MediaTemplate EmbedCab="yes" />
    <PropertyRef Id="WIX_IS_NETFRAMEWORK_462_OR_LATER_INSTALLED"/>
    <Condition Message='This setup requires the .NET Framework 4.7 client profile installed.'>
      <![CDATA[Installed OR WIX_IS_NETFRAMEWORK_462_OR_LATER_INSTALLED]]>
    </Condition>
    <Feature Id="Complete" Title="TestInstaller" Description="TestInstaller" Level="1" ConfigurableDirectory='INSTALLFOLDER'>
      <ComponentGroupRef Id="ProductComponents" />
      <ComponentGroupRef Id="ProductBinComponents" />

    </Feature>


    <UIRef Id="WixUI_Mondo" />
    <UIRef Id="WixUI_ErrorProgressText" />
  </Product>

  <Fragment>
    <Directory Id="TARGETDIR" Name="SourceDir">
     <Directory Id="INSTALLFOLDER" Name="Test Installer" >
        <Directory Id="INSTALLBINFOLDER" Name="bin">
        </Directory>
      </Directory>
    </Directory>
  </Fragment>

  <Fragment>
    <ComponentGroup Id="ProductComponents" Directory="INSTALLFOLDER">
      <Component Id="ProductComponent" Win64="yes" Guid="*">
        <File Source="C:\Temp\Publish\Web.config" />
        <File Source="C:\Temp\Publish\NLog.config"/>
        <File Source="C:\Temp\Publish\Global.asax"/>
      </Component>
    </ComponentGroup>
    <ComponentGroup Id="ProductBinComponents" Directory="INSTALLBINFOLDER">
      <Component Id="ProductBinComponent" Win64="yes" Guid="*">
        <File Source="C:\Temp\Publish\bin\Antlr3.Runtime.dll"/>
        <File Source="C:\Temp\Publish\bin\Antlr3.Runtime.pdb"/>
      </Component>
    </ComponentGroup>
  </Fragment>
</Wix>

However everytime I try to build it I get this message

'.', hexadecimal value 0x00, is an invalid character.

And I really do not know why because all files I can edit with notepad++ seems to have correct endings. so I am at a loss at even finding the place it is complaining about let alone trying to fix it. Anyone that could either point me in the right direction or know a good workaround ?

I know that there have been a similar bug in Wix as I can see there are quite a few out there asking about something similar however the ones I could find didn't apply to my problem or if it does I don't know where I can fix it because they where in a different version of Wix than I am.

I can add if I do the following in my wsx file it builds just fine. However that removes the user interface I would had liked to start working with.

 <!--<UIRef Id="WixUI_Mondo" />
<UIRef Id="WixUI_ErrorProgressText" />-->
Helbo
  • 473
  • 10
  • 32
  • Given that @BobArnson has answered this question, please [**accept**](https://meta.stackexchange.com/q/5234/234215) his answer and ask a new question for your new problem. Thanks. – kjhughes Aug 09 '18 at 16:19
  • @kjhughes As stated in my question I was asking how to fix this if I made an error or workaround this. his answer while it might be the correct answer it is not really trying to point me to a fix or a workaround for Wix V4. – Helbo Aug 09 '18 at 16:25
  • [Please check if this problem is solved by the suggested fix to your other question](https://stackoverflow.com/a/51777376/129130). Could you conceivably have included Wix.dll or another unwanted DLL? Doesn't really make sense, but maybe give it a try. Also, I don't see a `` entry in your WiX source? Maybe you just didn't include it when pasting? Maybe the error progress entry includes it? [See sample RTF license file inclusion](https://stackoverflow.com/a/47972615/129130) (bottom WiX markup). – Stein Åsmul Aug 10 '18 at 00:44
  • [**I updated my answer to your other question**](https://stackoverflow.com/a/51777376/129130). I wonder if this `WixVariable` entry worked for your WiX 4 project as well? Would be very useful for the rest of us to know. – Stein Åsmul Aug 10 '18 at 13:26
  • @SteinÅsmul I will make sure to test this. however I am current under the clock to complete something before my vacation next week where I will be having a week away from the internet so I will not be able to come back with a answer until I am back again in about 10 days time – Helbo Aug 10 '18 at 13:44
  • Enjoy the rehab :-). T minus 10 days. Have fun! Good luck with your deadline. – Stein Åsmul Aug 10 '18 at 13:54
  • 1
    @SteinÅsmul I have tried putting in the WixVariable entry in to my version 4 installer now and apparently it seem to have solved the issue. so it seems that if there are no WixVariable with a rtf reference then it will come up with this error. – Helbo Aug 20 '18 at 06:33

1 Answers1

1

That's a bug in WiX v4, which is still in active development. The most recent stable release is v3.11.1, which you can get from http://wixtoolset.org/releases/.

Bob Arnson
  • 21,377
  • 2
  • 40
  • 47
  • well I tried the v3 also after I got this error but there I get a different error that I couldn't solve either... 'Either Microsoft.Tools.WindowsInstallerXml.AssemblyDefaultWixExtensionAttribute was not defined in the assembly or the type defined in extension WixUIExtension.dll could not be loaded.' are there no workaround on the v4 ? even if it is in active development ? – Helbo Aug 09 '18 at 16:21