Reputation: 814
I have seen many ways to convert json array into string but none of them are working.
Can anyone help me how do I convert json array into string in wcf.
Please help me through it.
Upvotes: 0
Views: 97
Reputation: 1545
I using JSON.NET for serialize and deserialize objects. You can install it with nuget, http://www.nuget.org/packages/Newtonsoft.Json/
MyObject result = Newtonsoft.Json.JsonConvert.DeserializeObject<MyObject >(jsonString);
string stringResult = Newtonsoft.Json.JsonConvert.SerializeObject(myObject);
Upvotes: 1