|
I've continued investigating thisand as a result have learnt a bit more about JSON.
{
"result": {
"status": 1,
"output": {
"user_id": "15452349"
},
"errors": []
}
}
It seems that this is not an array but an object (with a possible array of errors) and therefore I need a custom JSON converter class.
So, I created a class that subclasses 'JsonConverter' and then another class that is a representation of the JSON above.
However when the program gets to the overriden ReadJson function, it fails at the point of doing:
JObject obj = (JObject)serializer.Deserialize(reader);
Can anybody explain why this might be happening?
|