[ServiceContract] public interface IService1 { [OperationContract] [WebGet(ResponseFormat=WebMessageFormat.Json)] DataSet GetData(string prodID); } public class Service1 : IService1 { public DataSet GetData(string prodID) { DataSet ds = new DataSet(); // //I am populating the dataset here // return ds; //how should I make it in json format now. } }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)