开发者

Serialize ASP.NET Web Service HTTP POST request results

I am trying to serialize my webmethod output (rename XML element with results), So far

[return: System.Xml.Serialization.SoapElementAttribute("results")]

before method declaration works fine with soap requests, but I am looking for something that would work the same way with HTTP POST/GET requests as well (right now I get retu开发者_运维百科rn class name as element name)


Have you considered using ASP.NET WebAPI? I think this is what you are looking for if you just beginning your project. You can find a step-by-step tutorial here: http://www.asp.net/web-api/overview/getting-started-with-aspnet-web-api/tutorial-your-first-web-api

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜