How to deserialise a json field with different data types using System.Web.Script.Serialization.JavaScriptSerializer

218 views Asked by At

I have a json object which may contain different types for a property. e.g. that status property can have a single string or an object. How can I deserialize this json object using JavaScriptSerializer? (not JsonConverter in json.net )

{"result":
    [
        {"grn":"12345678","status":{"message":"Partnership successfully listed!","partnership_info":null}},
        {"grn":"12345612","status":"Partnership is already listed!"}
    ]
}
0

There are 0 answers