Invalid postback or callback argument

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Mike P

    Invalid postback or callback argument

    I have added a couple of buttons to my ASP.NET 2.0 page. which both are
    meant to do pretty simple things, a Back button and a Submit data
    button. But I get this error whenever I click either of the buttons :

    Invalid postback or callback argument. Event validation is enabled
    using <pages enableEventVali dation="true"/> in configuration or <%@ Page
    EnableEventVali dation="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
    ClientScriptMan ager.RegisterFo rEventValidatio n method in order to
    register the postback or callback data for validation.


    How do I prevent this error?


    *** Sent via Developersdex http://www.developersdex.com ***
  • clickon

    #2
    RE: Invalid postback or callback argument

    This event usually happens when validation is enabled and you have either,
    added fields to the form on the clientside and/or you have submitted the form
    before the following hidden field has been rendered,

    <input type="hidden" name="__EVENTVA LIDATION" id="__EVENTVALI DATION"
    value="/wEWBALDgtmMCQLm wMTlCwLT/KSEAQKt7K6OC7Qm o2W+MsXlihjcAaI c/unn8Nw3" />.

    Basicaly ASP.net is trying to make sure that the form being submitted is the
    same form that it rendered.

    "Mike P" wrote:
    [color=blue]
    > I have added a couple of buttons to my ASP.NET 2.0 page. which both are
    > meant to do pretty simple things, a Back button and a Submit data
    > button. But I get this error whenever I click either of the buttons :
    >
    > Invalid postback or callback argument. Event validation is enabled
    > using <pages enableEventVali dation="true"/> in configuration or <%@ Page
    > EnableEventVali dation="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
    > ClientScriptMan ager.RegisterFo rEventValidatio n method in order to
    > register the postback or callback data for validation.
    >
    >
    > How do I prevent this error?
    >
    >
    > *** Sent via Developersdex http://www.developersdex.com ***
    >[/color]

    Comment

    • Mike P

      #3
      Re: Invalid postback or callback argument

      Figured this out myself...a </form> tag that shouldn't have been there
      was causing this error.



      *** Sent via Developersdex http://www.developersdex.com ***

      Comment

      Working...