Search Unity

UWP build, error: namespace Formatters does not exist

Discussion in 'Windows' started by tom_carr_2, Aug 4, 2016.

  1. tom_carr_2

    tom_carr_2

    Joined:
    Dec 24, 2015
    Posts:
    18
    Hi,
    Trying to build Universal 10 player. got error:

    Assets\Scripts\Data\DataController.cs(4,36): error CS0234: The type or namespace name 'Formatters' does not exist in the namespace 'System.Runtime.Serialization' (are you missing an assembly reference?)

    here is line 4:
    using System.Runtime.Serialization.Formatters.Binary;

    I'm using a binary file to keep log in info for player.
    Works fine, standalone builds fine.

    What is namespace for formatting binary files with UWP?
    Thanks, Tom
     
    daniel_alves_bra likes this.
  2. tom_carr_2

    tom_carr_2

    Joined:
    Dec 24, 2015
    Posts:
    18
    solved my own question, maybe it will help others. windows store does not support binary formatter. unity really should have this in the documentation as it looks like binary formatter is only a tool for standalone. i'm actually storing data on server side, so I just need username and password to access the data on server, so I'll just use playerprefs.
     
    arielfel and daniel_alves_bra like this.
  3. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    10,680
  4. tom_carr_2

    tom_carr_2

    Joined:
    Dec 24, 2015
    Posts:
    18
    thanks,didn't see that in the manual.