Using JValue.Value |
JValue s = new JValue("A string value"); Console.WriteLine(s.Value.GetType().Name); // String Console.WriteLine(s.Value); // A string value JValue u = new JValue(new Uri("http://www.google.com/")); Console.WriteLine(u.Value.GetType().Name); // Uri Console.WriteLine(u.Value); // http://www.google.com/