0
http://localhost:51238/RestService.svc/FOSLoadingS1Opening?Data=[
{
"Name":"Sachin",
"City":"Bengalueu",
"FimStatus":"false",
"Deno1":"50",
"Deno2":"100",
"Deno3":"500",
"Deno4":"2000",
"IndtVal1":"2500",
"IndtVal2":"5000" }]
我能夠通過查詢字符串傳遞json字符串。但是,當我想要傳遞無查詢字符串時,我收到錯誤。如何使用WCF在UriTemplate中傳遞JSON字符串而不使用查詢字符串
http://localhost:51238/RestService.svc/FOSLoadingS1Opening/[
{
"Name":"Sachin",
"City":"Bengalueu",
"FimStatus":"false",
"Deno1":"50",
"Deno2":"100",
"Deno3":"500",
"Deno4":"2000",
"IndtVal1":"2500",
"IndtVal2":"5000" }]
當我通過上面的URL我得到錯誤「錯誤的請求」。
我想傳遞json字符串而不使用查詢字符串。請建議如何實現。
唯一的方法是使用webinvoke(post)而不是webget –