hi,
i tried following the Person class example based on a previous (old)
post, but everytime i do an deserialization back to a Person object
the following error always gets displayed: "Unable to cast object of
type 'Jayrock.Json.JsonObject' to type Person".
this is my code:
public class Person
{
public string name;
public int age;
}
Person p1 = new Person();
p1.name = "john";
p1.age = 28;
string x = JsonConvert.ExportToString(p1);
Person p2 = (Person)JsonConvert.Import(x); // this line throws the
error
thanks.