Get value from JSON with JSON.NET

后端 未结 3 1194
眼角桃花
眼角桃花 2020-12-01 13:47

I try to use http://www.codeplex.com/Json to extract values ​​from a json object.

I use imdbapi.com and they return json like this:

{\"Title\": \"Sta         


        
3条回答
  •  南笙
    南笙 (楼主)
    2020-12-01 14:28

    class TypeHere{
       string Name {get;set;}
    }
    
    TypeHere object = JsonConvert.DeserializeObject< TypeHere >(jsonString)
    
    // Ex. output 
    object.Name;
    

提交回复
热议问题