Search Unity

  1. If you have experience with import & exporting custom (.unitypackage) packages, please help complete a survey (open until May 15, 2024).
    Dismiss Notice
  2. Unity 6 Preview is now available. To find out what's new, have a look at our Unity 6 Preview blog post.
    Dismiss Notice

XmlSerializer Deserialize () System.NotSupportedException

Discussion in 'Windows' started by FlashMuller, Jan 6, 2016.

  1. FlashMuller

    FlashMuller

    Joined:
    Sep 25, 2013
    Posts:
    451
    Hey guys,
    I'm using the XmlSerializer class to save and load date. Just to make sure: I do know that System.IO is not supported on WSA and can tell that I've worked around that (using UnifiedIO from the AssetStore).

    Now: I can create my XML using XmlSerializer.Serialize(), store and open it; it works. I can NOT however Deserialize using the XmlSerializer, which is quite frankly just weird. The exception is below.

    Additional information: XLinqException thrown: 'System.NotSupportedException' in SYSTEM.XML.SERIALIZATION.NI.DLL

    Can anyone help on how to either get it working or work around that with a different class?

    Thanks,
    Daniel
     
  2. Aurimas-Cernius

    Aurimas-Cernius

    Unity Technologies

    Joined:
    Jul 31, 2013
    Posts:
    3,737
  3. FlashMuller

    FlashMuller

    Joined:
    Sep 25, 2013
    Posts:
    451
    Aurimas,
    thanks for the link. But Deserialize / the XmlSerializer doesn't seem to be a part of that collection - or am I missing something?
    Thanks!
     
  4. Aurimas-Cernius

    Aurimas-Cernius

    Unity Technologies

    Joined:
    Jul 31, 2013
    Posts:
    3,737
    Those might be available on the system, we were only adding missing items. If you code compiles using .NET Core (default), then you are fine with it. I was referring more to System.IO replacements.