Shane

Shane

  • NA
  • 1
  • 0

Json object in C#

Apr 6 2007 4:42 PM
Okay, so I am brand spanking new to C#, got assigned something and now find myself working in c#. I am using this jrock library to create JSON objects for talking back to this servlet I have (that is written in java). THe JSON object I can build up and then do a call on the object:

string ret = myJsonObj.ToString();

but ret has a string that has extra characters that makes my socket code honk..namley a \" how do I supress these I need a string like:

{"sessionKey":"The key #4241242132","method":"init"}

what it is returning form ToString(); though:

{\"sessionKey\":\"The Key #4241242132\",\"method\":\"init\"}

how do I stop those slashes? thanks

Shane

Answers (1)