csharp object to json string
Code Example - csharp object to json string
Newtonsoft.Json.JsonConvert.SerializeObject(new {foo = "bar"})
object to json csharp
using Newtonsoft.Json;
var jsonString = JsonConvert.SerializeObject(obj);
how to convert object in string JSON csharp
var json = new JavaScriptSerializer().Serialize(obj);
csharp convert object to json
var jsonString = JsonConvert.SerializeObject(ObjectModel);
csharp convert object to string
Object obj=new Object();
obj="hi";
string str1=Convert.ToString(obj);
string str2=obj.ToString();
string str3= obj as string;
string str4=(string)obj;
csharp convert ad objectguid to string
new Guid((System.Byte[])this.GUID).ToString()
string to json csharp
JObject json = JObject.Parse(str);
string json to class csharp
var result = JsonConvert.DeserializeObject<YourClass>(jsonstring);
csharp print object to json
var json = new JavaScriptSerializer().Serialize(ObjectModel);