Assembly: System.Web.Helpers (in System.Web.Helpers.dll)
Thetype exposes the following members.
This class represents a helper, which is a component that simplifies web programming in ASP.NET Web Pages. You can use the class to encode or decode data in JSON format.
HTTP requires structured data to be converted, or serialized, to a format that can be read across the web by different processes. Popular serialization formats are JSON and XML, which are both are text-based formats. A typical use for the JSON format is to retrieve data from a database, a web service, or other sources, encode it in JSON format, and then return it to a requesting browser as part of a web page.
When users have finished viewing the page that contains the data, they can submit the page. In the server-side page code, when you receive posted JSON data, you can use the Decode(String) method to convert the data from JSON format into a data object. You can then use code (for example, a foreach loop) to process the posted data and perform tasks such as updating a database, displaying the updated data on the page, or serving the data to other requests by using a web service.