Specifying fallback culture

Sep 27, 2015 at 1:35 PM
Hi Oleg, could you please tell is there a way to specify a fallback culture for a managed project when it is linked by light.exe? Should I link and compile it manually using custom arguments string outside of Visual Studio in this case?
I've checked sources of the compiler and it seems to be that only project.Language is included in "-culture" option which is passed to light. Also wixsharp csproj.user file contains "<FallbackCulture>" element that has no effect.
Sep 28, 2015 at 2:52 AM
Indeed FallbackCulture has no effect as Wix# compiler does not rely on VS project infrastructure (so it's possible to compile MSI without using VS at all).

You are also right that project.Language is the value that gets passed to light.exe with "-culture" option. However the current implementation does not allow multiple languages to be specified and this is the problem for the cases like yours. Unfortunately there is no a good work around. The only thing you can do is to call BuildMsiCmd instead of BuildMsi and then modify the produced batch file to include extra culture for the "-culture" option. But it is a clumsy work around.

If you don't want to wait for the next release you can use the 'HotFix' NuGet release v1.0.27.1 that has support for multiple languages (e.g.Project.Language="en-US,en-AU").

You can get it with this NuGet command:
Install-Package WixSharp.bin -Pre
Sep 28, 2015 at 8:39 PM
I see, thanks a lot for the quick fix! No issues so far on 1.0.27.1, fallback works as expected
Sep 29, 2015 at 1:05 AM
Great. Thank's for letting me know.
I actually didn't have a good test case to verify the fix so marking the issue (#72) as resolved was a little bit of 'gambling'. :)