|
Rank: Member Groups: Member
Joined: 10/12/2007 Posts: 13
|
Hi,
I have a gridview control in a callback-panel. Everything works fine, but when I'm includng the grdview in the Callback-Trigger and select a record in the gridview, the follwing error occurs:
______________________ (origingal in german language) Ungültiges Postback- oder Callbackargument. Die Ereignisvalidierung wird mithilfe von <pages enableEventValidation="true"/> in der Konfiguration oder mithilfe von <%@ Page EnableEventValidation="true" %> auf einer Seite aktiviert. Aus Sicherheitsgründen überprüft dieses Feature, dass Argumente für Postback- oder Callbackereignisse von dem Serversteuerelement ausgehen, von dem sie ursprünglich gerendert wurden. Wenn die Daten gültig sind und erwartet wurden, verwenden Sie die ClientScriptManager.RegisterForEventValidation-Methode, um die Postback- oder Callbackdaten für die Validierung zu registrieren. ______________________ (translated by myself) invalid Postback- oder Callbackargument. the event validation supported by <pages enableEventValidation="true"/> in the configuration or supported by <%@ Page EnableEventValidation="true" %> on a page was activated. Due to security reasons this feature checks, that the argument for postback- or callback-events from the servercontrol are the same, like they are renderd previously. If this data is valid, use the ClientScriptManager.RegisterForEventValidation-Methode, to registrate the Postback- orCallbackdata for validation.
Do you have an example, where and how to use the "ClientScriptManager.RegisterForEventValidation-Method" ?
|
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,194
|
Hi, This is an issue that does not seem to be related to our controls at all. Please check the following post: http://forums.asp.net/t/973410.aspxThe only thing you need to check with our CallbackPanel is the page encoding. The requestEncoding and responseEncoding in your web.config must be UTF-8. Other than that the CallbackPanel is transparent to postbacks. Thanks
|
|
Rank: Member Groups: Member
Joined: 10/12/2007 Posts: 13
|
right, that wasn't the issue. I've made further investigations and found out, that the problem is that by selecting a datarow I want to do a response.redirect to proceed to another page.
So what should I do now?
Is there a way to tell the callbackpanel, that I want to trigger the "gridview_sorted" and "gridview_paging" events, but not the "gridview_Response" event?
|
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,194
|
Hi,
The CallbackPanel works transparently, which means the whole thing works as if the CallbackPanel did not exist. So there is no such saying as telling the CallbackPanel to trigger what, not to trigger what. Whatever event that are triggered are triggered by the GridView (or any other controls that you put in your page), not by our CallbackPanel. Our CallbackPanel is just a carrier.
None of the problems you have posted so far has anything to do with our controls. So you really should not automatically associate whatever problem you see with our controls just because you have them in your page. If you suspect a problem with our product, try to isolate and reproduce the error in a separate page. Most of the time you will find out what’s wrong while doing that. If you can not, we would be happy to take a look of the reproducing code.
Thanks
|
|
Rank: Member Groups: Member
Joined: 10/12/2007 Posts: 13
|
I've found out, that the callback panel has its own redirect property. Using this, it works fine. So it is a matter of your control, even I should have read the documentation more carefully.
|
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,194
|
Good job! That's what the documentation is for!
|
|