Top "Json.net" questions

Json.

How can I return camelCase JSON serialized by JSON.NET from ASP.NET MVC controller methods?

My problem is that I wish to return camelCased (as opposed to the standard PascalCase) JSON data via ActionResults from …

asp.net-mvc json json.net camelcasing
How to access elements of a JArray (or iterate over them)

I have the following Json gotten from Twitter + token {[ { "trends": [ { "name": "Croke Park II", "url": "http://twitter.com/search?q=%22…

c# .net twitter json.net
Get value from JToken that may not exist (best practices)

What's the best practice for retrieving JSON values that may not even exist in C# using Json.NET? Right now …

c# json.net
Iterating over JSON object in C#

I am using JSON.NET in C# to parse a response from the Klout API. My response is like this: [ { "…

c# json c#-4.0 json.net
Casting interfaces for deserialization in JSON.NET

I am trying to set up a reader that will take in JSON objects from various websites (think information scraping) …

c# .net json json.net
Getting the name / key of a JToken with JSON.net

I have some JSON that looks like this [ { "MobileSiteContent": { "Culture": "en_au", "Key": [ "NameOfKey1" ] } }, { "PageContent": { "Culture": "en_au", "Page": [ "about-us/" ] } } ] …

c# json json.net
Converting a JToken (or string) to a given Type

TL;DR Version I have a object of type JToken (but can also be a string) and I need to …

c# windows-phone-7 json.net restsharp
JSON.Net Self referencing loop detected

I have a mssql database for my website within 4 tables. When I use this: public static string GetAllEventsForJSON() { using (CyberDBDataContext …

c# serialization json.net
Json.NET serialize object with root name

In my web app I'm using Newtonsoft.Json and I have following object [Newtonsoft.Json.JsonObject(Title = "MyCar")] public class …

c# asp.net .net json json.net
Checking for empty or null JToken in a JObject

I have the following... JArray clients = (JArray)clientsParsed["objects"]; foreach (JObject item in clients.Children()) { // etc.. SQL params stuff... command.…

c# sql json.net