相关文章推荐
I am using a dynamically created radgrid with custom filtering and sorting. After the grid displays the results, I go to 2nd page and select a row and it opens a popup window. I close that window and click on the previous page pager button and it give me the below error.
"Event validation is enabled using <pages enableEventValidation="trur"/> in configuration or %@Page EnableEventValidation="true"%
I tried setting EnableEventValidation="true"% but it is not pagging correctly. I checked the forms and found similar problem but it did not solve my problem. Any help will be appreciated.
Thanks,
Hello Raji,
Make sure that you are using Advanced data binding using NeedDataSource event. Also Paging with disabled control ViewState is not supported. Try setting EnableViewState property of the RadGrid / MasterTableView is set to true .
-Shinu.
Hi Raji,
The EventValidation feature is part from the Security settings of ASP.NET and it is enabled by default for the page. This kind of error is received when you are modifying the page on the client. By default the ASP Isapi filter expects to see the same control the was rendered the last time. If you have modified these controls and the EventValidation is enabled, exception is raised.. I think in your case, that has something to do with your custom paging. More about EvenValidation property of ASP.NET page you could find in this MSDN thread.
There are two ways to resolve this issue:
1. To disable event validation by setting value "false" to the EnableEventValiodation property in the @Page directive. This is the easier approach, but the security level will drop. It is up to you to decide this.
2. The second approach is to use RegisterForEventValidation method, like described here . This is the harder approach, but with ti you are preserving the security settings.
Regards,
Andrey
the Telerik team If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now
 
推荐文章