0

I have a repeater which nests one or more custom control instances. Each custom control instance has a drop down and a button called "Update".

This all works fine when JS is on.

However with JS off, I get the "Invalid postback or callback argument. Event validation is enabled..." error.

Thinking about this, I imagine the following is happening:

ASP.NET creates ViewState for the page. When the page is posted back, the viewstate should be passed back to the page via the js hooks that ASP.NET puts in place.
However, because JS is OFF, this isn't passed back. ASP.NET then flags a mismatch between the ViewState that it expects, and the Viewstate that it receives.

Is this correct?

In which case, what is the recommended action that I take?

Thanks

Duncan
  • 10,218
  • 14
  • 64
  • 96

1 Answers1

0

try to set EnableEventValidation="False" or ValidateRequest="False". hope it will work.

Thanks

Shakeeb Ahmed
  • 1,778
  • 1
  • 21
  • 37
  • Thanks, I'm sure this will work but that leaves the site open to XSS so it's not something I can do I'm afraid. – Duncan Dec 04 '10 at 11:51