VBISCOOL2
09-20-2006, 03:02 AM
Hello.
I have a webform with a button and a text box. I am also using a codebehind file. When the user presses the button a connection to the database is made and a stored procedure is executed and the number of rows affected is returned.
This is my @Page:
<%@ Page EnableSessionState="false" EnableEventValidation="true" EnableViewState="false" Language="VB" CodeFile="index.aspx.vb" Inherits="IndexPg" %>
However, I am getting the following error when I press the button at runtime:
==========================================================
Server Error in '/WebSite2' Application.
--------------------------------------------------------------------------
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.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: 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.
----------------------------------------------------------------
Thanks for any help! ;)
I have a webform with a button and a text box. I am also using a codebehind file. When the user presses the button a connection to the database is made and a stored procedure is executed and the number of rows affected is returned.
This is my @Page:
<%@ Page EnableSessionState="false" EnableEventValidation="true" EnableViewState="false" Language="VB" CodeFile="index.aspx.vb" Inherits="IndexPg" %>
However, I am getting the following error when I press the button at runtime:
==========================================================
Server Error in '/WebSite2' Application.
--------------------------------------------------------------------------
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.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: 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.
----------------------------------------------------------------
Thanks for any help! ;)