using System.Collections;
using System.Collections.Generic;
using Newtonsoft.Json.Linq;
using Newtonsoft.Json.Converters;
using Newtonsoft.Json.Serialization;
namespace Question42115402
public Person (string PK_R_PERSON, string FIRSTNAME, string LASTNAME)
this.PK_R_PERSON = PK_R_PERSON;
this.FIRSTNAME = FIRSTNAME;
this.LASTNAME = LASTNAME;
public string PK_R_PERSON { get; set; }
public string FIRSTNAME { get; set; }
public string LASTNAME { get; set; }
static string GetResponse()
{""id"":293,""firstname"":""jos"",""lastname"":""don""},
{""id"":1861,""firstname"":""jef"",""lastname"":""dan""},
{""id"":1896,""firstname"":""janine"",""lastname"":""din""}]
public static void Test()
var response = GetResponse();
Console.WriteLine("Response: ");
Console.WriteLine(response);
var root = JToken.Parse(response);
.SelectTokens("[*].PersonsTable[*]")
.Select(data => new Person((string)data["id"], (string)data["firstname"], (string)data["lastname"]))
Console.WriteLine("Result of parsing: ");
Console.WriteLine(JsonConvert.SerializeObject(persons, Formatting.Indented));
public static void Main()
Console.WriteLine("Json.NET version: " + typeof(JsonSerializer).Assembly.FullName);