Reading and writing JSON in C#

C# is a common client-side language for rich applications as well as for writing the client implementation of web services running on ASP.NET. The .NET library includes JSON serialization and deserialization in the System.Web.Extensions assembly.

Getting ready

This example uses the built-in JSON serializer and deserializer in the System.Web.Extensions assembly, one of the many .NET libraries that are available. If you've installed a recent version of Visual Studio (see https://www.visualstudio.com/en-us/downloads/visual-studio-2015-downloads-vs.aspx), it should be available. All you need to do to use this assembly is include it in the assemblies your application references in Visual Studio by right-clicking the References ...

Get JavaScript JSON Cookbook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.