0

I'm using Newtonsoft.Json to turn json into objects, that works fine. I was wondering if there's a nice way to reverse the process noting that i dont want to jsonise all the object fields. To paraphrase, is there a way to use Newtonsoft.Json to produce thinned down jsonised object representations?

James Newton-King
  • 48,174
  • 24
  • 109
  • 130
Sheena
  • 15,590
  • 14
  • 75
  • 113
  • 2
    possible duplicate of [Easiest way to serialize and store objects in c#?](http://stackoverflow.com/questions/6719498/easiest-way-to-serialize-and-store-objects-in-c) – genesis Jul 19 '11 at 12:01
  • not really, the responses mostly say things like 'json is friendly', my question is a whole lot more specific – Sheena Jul 19 '11 at 14:58

1 Answers1

1

Have you tried using the JsonIgnore to opt-out properties that you don't want to be included in the JSON serialization? See this topic:

http://james.newtonking.com/projects/json/help/ReducingSerializedJSONSize.html

Andrew Brown
  • 4,086
  • 1
  • 24
  • 21