阅读背景:

我可以在ASMX JSON服务上设置HTTP响应代码并引发异常吗?

来源:互联网 

In an ASP.NET ASMX WebMethod that responds JSON, can i both throw an exception & set the HTTP response code? I thought if i threw an HttpException, the status code would be set appropriately, but it cannot get the service to respond with anything but a 500 error.In an ASP.NET ASMX WebMethod that responds JSON




你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: