Is it possible to return a JArray object from a [WebMethod] using jQuery ajax and Json.NET? Example:
[WebMethod]
public JArray GetJsonData()
{
JArray jArray = new JArray();
JObject jObject = new JObject();
jObject.Add(new JProperty("name", "value"));
jArray.Add(jObject);
return jArray;
}
When I call this using jQuery ajax, it returns something that looks like this:
[[[[]]]]
I believe you need to return a string.