Groups | Blog | Home
all groups > dotnet clr > january 2008 >

dotnet clr : Error Message in ASP.NET 2.0


Techeek
1/6/2008 7:40:01 AM
I am getting this error on click of a link button. If anbody has
got the same error and have a solution for it plese respond.

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.
--
techeek
Misbah Arefin
1/16/2008 12:10:00 AM
One solution (although not the best solution) try adding this into the
<system.web> section of your web.config file:

<pages enableEventValidation="false" />



Another solution is to register your control for event validation. Simply
add the following call in the PreRender or Render page life cycle then your
control should work without having to turn off eventValidation:

Page.ClientScript.RegisterForEventValidation(this.UniqueID);



--
Misbah Arefin



[quoted text, click to view]
Sanket Sirotiya
1/29/2008 2:39:40 PM
<%@ Page EnableEventValidation="false" %> is the best way to overcome this.

--
Thanks,
Sanket Sirotiya
(sanket.sirotiya@yahoo.com)
[quoted text, click to view]
AddThis Social Bookmark Button