You’re looking for the JavaScriptSerializer
class, which is used internally by JsonResult:
string json = new JavaScriptSerializer().Serialize(jsonResult.Data);
More Related Contents:
- Deserialize JSON into C# dynamic object?
- How do I turn a C# object into a JSON string in .NET?
- Does Json.NET cache types’ serialization information?
- Using JsonConvert.DeserializeObject to deserialize Json to a C# POCO class
- JavaScriptSerializer.Deserialize – how to change field names
- JSON.Net throws StackOverflowException when using [JsonConvert()]
- “Self Referencing Loop Detected” exception with JSON.Net
- Circular reference detected exception while serializing object to JSON
- Deserializing JSON to abstract class
- Deserialize json array stream one item at a time
- Not ableTo Serialize Dictionary with Complex key using Json.net
- How to deserialize a JSON property that can be two different data types using Json.NET
- How to make JSON.Net serializer to call ToString() when serializing a particular type?
- caliburn.micro serialization issue when implementing PropertyChangedBase
- Json.NET custom serialization with JsonConverter – how to get the “default” behavior
- How to apply indenting serialization only to some properties?
- Ignoring a field during .NET JSON serialization; similar to [XmlIgnore]?
- Ignoring null fields in Json.net
- Convert DataTable to JSON with key per row
- Use different name for serializing and deserializing with Json.Net
- Deserialize specific enum into system.enum in Json.Net
- Json.NET: Deserializing nested dictionaries
- C# JSON custom serialization
- Change default date serialization in WCF
- How to serialize or deserialize a JSON Object to a certain depth in C#?
- Deserializing JSON into an object with Json.NET
- Ignore Base Class Properties in Json.NET Serialization
- How to deserialize JSON to objects of the correct type, without having to define the type before hand?
- How to globally set default options for System.Text.Json.JsonSerializer?
- Json.net serialization of custom collection implementing IEnumerable