How would I read into a 'nested' Json file with 'DataContractJsonSerializer' in C# .NET (win7 phone)? How would I read into a 'nested' Json file with 'DataContractJsonSerializer' in C# .NET (win7 phone)? json json

How would I read into a 'nested' Json file with 'DataContractJsonSerializer' in C# .NET (win7 phone)?


You could add a wrapper class:

[DataContract]public class Wrapper{    [DataMember]    public myInfo Main { get; set; }    [DataMember]    public myInfo Something { get; set; }}

Now you could deserialize the JSON back to this wrapper class and use the two properties to access the values.