“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.”
Answer :
——–
# re: EnableEventValidation error on button postback using a multipart form in .NET v2.0 I had a similiar problem. I fixed it by putting my databinding code in the Page_Load event in a !Page.IsPostBack block. I got the solution here:
2]Invalid attempt to read when no data is present
answer
——–
reader obj should use as shown below
sqlReader = sqlCmd.ExecuteReader();
sqlReader.Read();
txtBkNum_brw.Text = sqlReader["BookNumber"].ToString();
txtBookTtl_brw.Text = sqlReader["BookTitle"].ToString();
txtAuth_brw.Text = sqlReader["Author"].ToString();
comboBox1.Text = sqlReader["Category"].ToString();
sqlReader.Close();