Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8546155
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T12:57:09+00:00 2026-06-11T12:57:09+00:00

I am new to JSon, especially JSon.Net. I am trying to use the LiveSDK

  • 0

I am new to JSon, especially JSon.Net. I am trying to use the LiveSDK on Windows Phone and i am having an issue parsing out the JSon response. I am trying to read calendar information and I can’t get it to parse. Below is my code for downloading the Json and my class definition. I get an exception on the line defining ‘user’.

    void getCal_DownloadCompleted(object sender, LiveDownloadCompletedEventArgs e)
    {
        if (e.Error == null)
        {
            using (var reader = new StreamReader(e.Result))
            {
                var json = reader.ReadToEnd();
                var user = JsonConvert.DeserializeObject<Calendar>(json);
            }
        }
    }

My Calendar class

    [JsonObject(MemberSerialization.OptIn)]
public class Calendar
{    
    [JsonProperty(PropertyName="name")]
    public string Name{get; set;}
    [JsonProperty(PropertyName = "id")]
    public string Id{get; set;}
    [JsonProperty(PropertyName = "description")]
    public string Description{get; set;}
    [JsonProperty(PropertyName = "created_time")]
    public string CreatedTime{get; set;}
    [JsonProperty(PropertyName = "updated_time")]
    public string UpdatedTime{get; set;}
    [JsonProperty(PropertyName = "from")]
    public object From{get; set;}
    [JsonProperty(PropertyName = "is_default")]
    public bool IsDefault{get; set;}
    [JsonProperty(PropertyName = "subscription_location")]
    public string SubscriptionLocation{get; set;}
    [JsonProperty(PropertyName = "permissions")]
    public string Permissions{get; set;}
}

The JSon Format received

    {
    "data": [
  {
     "id": "calendar.42d4dbc866f94c83849c88c6eb9985bc", 
     "name": "Birthday calendar", 
     "description": "If you have birthdays listed for your contacts, they'll appear on this calendar. You can add more birthdays, but you can't add other types of events.", 
     "created_time": "2011-08-05T19:41:04+0000", 
     "updated_time": "2011-08-05T19:41:04+0000", 
     "from": {
        "name": null, 
        "id": null
     }, 
     "is_default": false, 
     "subscription_location": null, 
     "permissions": "read"
  },{
     ...
  }

]
}

I was no having luck using the LiveSDK GetAsync() so i went with DownloadAsync() instead. Is this approach better?

Thanks

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-11T12:57:10+00:00Added an answer on June 11, 2026 at 12:57 pm

    Your serialization class doesn’t seem to match the JSON. JSON is returning an object with one property called data that is an array containing elements with the Calendar class you defined.

    Try adding a new class like:

    [JsonObject(MemberSerialization.OptIn)]
    public class AppointmentList
    {
        [JsonProperty(PropertyName="data")]
        public List<Calendar> data {get; set;}
    }
    

    and deserialize like:

    var user = JsonConvert.DeserializeObject<AppointmentList>(json);
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm new with JSON.NET and I'm trying to deserialize a JSON string to a
I am new to programming especially jQuery. I am trying to sort (order) images
i'm trying to parse some json in perl, but am having problems with it.
Im new to Javascript stuff especially on JSON and Jquery. I have successfully implement
I have spent days on this trying out all the JSON libraries including the
I am new to Dust.js and am trying to iterate a JSON object with
am new to Json so a little green. I have a Rest Based Service
Im new to JSON and php. I need to grab the lat and lng
I am new to json, js etc. So I am a bit confused about
I am very new to Json and my goal to create the Json output

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.