Code like this with button in footer template after clicking that button error appears:
<asp:Repeater runat="server" ID="RptrDetailsSideList" OnItemCommand='rptMyRepeater_ItemCommand'>
<ItemTemplate>
<li class="clearfix">
<div class="art-thumb">
<img src='<%#DataBinder.Eval(Container.DataItem, "listimage")%>' width="50" height="50" alt='<%#DataBinder.Eval(Container.DataItem, "listimagealt")%>' />
</div>
<div class="art-desc">
<time datetime="2011-08-27T13:30+00:00"></time>
<h3><a href="article.aspx?title=<%#DataBinder.Eval(Container.DataItem, "title")%>"><%#DataBinder.Eval(Container.DataItem, "listtile")%></a></h3>
<p><%#DataBinder.Eval(Container.DataItem, "listdescription")%></p>
</div>
</li>
</ItemTemplate>
<FooterTemplate>
<asp:Button runat="server" ID="btnRepeater" Text="TEST" CommandName='SomeAction' CommandArgument='100'/>
</ul>
</FooterTemplate>
</asp:Repeater>
The error is:
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.
Code for server side:
protected void rptMyRepeater_ItemCommand(object source, RepeaterCommandEventArgs e)
{
int x = 0;
}
What am I doing wrong ?
Here is the solution
http://weblogs.asp.net/gunnarpeipman/archive/2009/05/10/invalid-postback-or-callback-argument-event-validation-is-enabled-using-in-configuration.aspx
I hope this is the lat projekt using pure asp.net