Is Xml serialization available in .NET Maui?

Viewed 46

I'm starting developing a simple application in .NET Maui, trying to load some data structures from a XML file.

Unfortunately when I call the XmlSerializer constructor

var serializer = new System.Xml.Serialization.XmlSerializer(typeof(List<T>));

it gives me the following exception:

'System.IO.FileNotFoundException' in System.Private.CoreLib.dll Could not load file or assembly 'System.Private.CoreLib.XmlSerializers, Version=6.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e, processorArchitecture=AMD64'

The xml file path is correct and it exists, and I've tested the code in a different project (not Maui).

1 Answers
Related