1

I am currently creating a string extension namespace for c# and I want part of it to be able to parse to/from JSON. The option of json.net is not valid as I don't want any third-party libraries/namespaces going on. (as I cannot use other namespaces to create a namespace to help others, this would be absurd) I also don't want to use javascriptserializer as in order to use it a reference to System.Web.Script.Serialization must be and I don't want my namespaces' users to have to add a reference so that this question: Deserialize JSON with C# won't help me. I need the function to match any object. how can it be done?

thank you in advance!

Sohaib Jundi
  • 1,576
  • 2
  • 7
  • 15

1 Answers1

-1
 using Newtonsoft.Json.Linq;

// after you got json as string

JObject rss = JObject.Parse(json);
  • "The option of json.net is not valid as I don't want any third-party libraries/namespaces going on" –  Jul 24 '19 at 06:45