I am trying to parse a json file using json.net. The file looks like this
{X: { Title:\"foo\", xxxx:xxxx } } {Y: {ZZ: {Title: \"
You could also do it with JSONPath: node.SelectTokens("$..*");
node.SelectTokens("$..*");
Used like this:
var jObjectsWithTitle = node .SelectTokens("$..*") .OfType() .Where(x => x.Property("Title") != null);
Or just:
var jObjectsWithTitle = node.SelectTokens("$..[?(@.Title)]");