Last post Jan 14, 2012 05:11 AM by kvh
Jan 12, 2012 09:31 PM|kvh|LINK
I am filling 2 DropDownList controls (car mark->car model) with CascadingDropDown (AJAX Control Toolkit). it works very well,
but when I click Button on that Form I get error message "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."
I can get rid of error message by setting EnableEventValidation="false". However I googled that this is a security risk and better is to use ClientScriptManager.RegisterForEventValidation
but how exactly ClientScriptManager.RegisterForEventValidation is used with dropdown lists? maybe could provide a code sample as it is FAQ but working solution is hard to find.
Jan 13, 2012 03:24 AM|chetan.sarode|LINK
Please refer to these threads:
Jan 14, 2012 05:11 AM|kvh|LINK
I managed to solve the issue in a great way. there is a easy solution using JQuery and JSON to accomplish same goal.