ASP.NET Client to Server communication

最后都变了- 提交于 2019-12-05 13:35:52

WebMethod is used with ASMX web services, which Microsoft now considers to be "legacy technology". WCF services should be used instead. They support both SOAP over HTTP/HTTPS and REST-based or JSON services, so are much more flexible.

For this reason, I also recommend against PageMethods, even if they seem to be convenient.

For ICallbackEventHandler

  1. ViewState is always sent to the server in the ajax request, so it can be read and control state can be re-instantiated, but the ViewState is not updated on the server, or sent back to the browser in the ajax response.
  2. Form values are posted back to the server in the request.
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!