I am using the following code:
myObj jsonStream = ser.Deserialize<myObj>(jsonStream);
And all was working fine until the JSON that came back had a null value for one of the fields. i.e.:
"name" : null
During the deserialization process, it's throwing an exception. In my myObj, I have a member:
public string name;
How can I gracefully handle the odd null value coming back from my datasource using the System.Web.Script.Serialization assembly? I tried:
public string name = "";
But that didn't work.