i have created restful wcf service accepts , returns values in json format following method:
public _1003response<response1003> create1003record(_1003request request) { var result = usrrep.create1003record(request); return result; } public class _1003request { public customer customer { get; set; } public int customertempreference { get; set; } }
customer
class type generated entity framework. testing service using poster tool in firefox. don't know how pass json format request that? please me out?
you should able use valid json:
var request = { customer: { // in customer object here name: "test" }, customertempreference: 0 }
you can convert string using:
var jsonrequest = json.stringify(request);
Comments
Post a Comment