我有一个ASP.Net托管网站,它显示结果列表作为DataGrid或ASP.Net Repeater与结果分页.
如果通过按下上一个/下一个选项卡快速滚动页面,有时会抛出HttpUnhandledException并呈现调试页面而不是下一个结果列表.
调试屏幕如下:
System.Web.HttpUnhandledException: Exception of type 'System.Web.HttpUnhandledException' was thrown. ---> System.ArgumentException: Invalid postback or callback argument. Event validation is enabled using <pages enableEventValidation="true"/> in configuration or <%@ Page EnableEventValidation="true" %> in a page. For security purposes, this feature verifies that arguments to postback or callback events originate from the server control that originally rendered them. If the data is valid and expected, use the ClientScriptManager.RegisterForEventValidation method in order to register the postback or callback data for validation.
at …Run Code Online (Sandbox Code Playgroud)