I am new to WCF. I created one WCF service and returned the data as JSON data. I assigned the return data to GridView, it shows the data perfectly.
[OperationContract]
[WebInvoke(Method = "GET", BodyStyle = WebMessageBodyStyle.Bare, RequestFormat = WebMessageFormat.Json, ResponseFormat = WebMessageFormat.Json, UriTemplate="employee/{search}")]
List<Employee> Listing(string search);
Now, I want to display the JSON string in <div> element (to verify the data). I tried to show the return data,
dvJson.InnerHtml = esc.Listing("s");
it shows like this
Employee[]
How to display JSON string in div element using C#?
Thanks in advance.