How to access Json object property?

1

I'm getting via Ajax a Json object, and would like to turn it into a C # object and access its properties. How can I do this?


I ended up reversing the name of the variables ( objeto , itens ), the first are the items, and the second the objects themselves.

    
asked by anonymous 22.05.2015 / 14:10

1 answer

1

With the help of link Posted by Marciano.Andrade in the comment of my question, I came up with the solution. Home The issue is that I'm getting a list of objects, so just creating an array of such objects. Home Everything was resolved with the following line:

Aluno[] aluno = new JavaScriptSerializer().Deserialize<Aluno[]>(models);
    
22.05.2015 / 14:18