0

I'm migrating a .NET Framework class library to .NET 6, and one of the functions the library performs is the extraction of localisable resources in customer WPF assemblies containing BAML streams. Our existing code is based on the LocBaml sample application from Microsoft's GitHub repo, and uses the BamlLocalizer class, but this doesn't seem to function properly with some .NET 6 assemblies I compiled from Microsoft's own WPF samples GitHub repo. It throws a FileNotFoundException complaining that it can't find the assembly containing the BAML resources but reading elsewhere, it seems that BamlLocalizer doesn't support .NET:

Can't Use LocBAML with WPF NET 5.0 project in visual studio 2019

Localizing a WPF app running on .NET Core 3 in 2020

The links above suggest using .resx instead of BAML, implying that WPF is now a stale (dead?) technology, so I was wondering if there is any alternative to BamlLocalizer in .NET or if WPF support has indeed stalled.

ericc
  • 334
  • 1
  • 14
  • You compiled the locbaml code for net6? https://github.com/microsoft/WPF-Samples/tree/master/Tools/LocBaml – Andy Oct 29 '22 at 18:07
  • I did but this uses the BamlLocalizer class too which throws an exception trying to read BAML streams in. NET core /5/6 assemblies. – ericc Oct 29 '22 at 20:03

0 Answers0