I'm having problems controlling viewstate size in ASP.NET 2.0.
I have a repeater, which contains a gridview, which contains another
gridview. All this is databound to produce a 100page report (for printing).
No postback needed, no viewstate needed.
I've set EnableViewState="false" on everything I can see, including all the
controls, the form and the page itself. But the viewstate is still 10 lines
in notepad (without wrapping!). I assume this is the elusive ControlState
that I can't turn off?
I tried removing the form tag, but that broke the gridviews (they need form
runat="server").
Any ideas? I can serialize the viewstate to session / db, but frankly that's
stupid in this situation - I just don't need ANY viewstate.
Thanks,
John
PS. I suppose I could bodge a PageWithNoViewState class, with a empty
SavePageStateToPersistenceMedium() method. But do I really have to do that??