Ideal viewstate size
“How big is too big a ViewState?”
"The ideal size for a viewstate is around 7 KB; it is optimal if you can keep it down to 3 KB or so. In any case, the viewstate, no matter its absolute size, should never exceed 30% of the page size." [Dino]
ViewState is enabled on four levels: machine, application, page, and control. The machine and application levels are controlled by configuration file settings, while the page and control ViewState settings are controlled by properties. Most sites that use ASP.NET will use ViewState in at least portions of the site, so turning it off at the machine or application level often is not feasible. Therefore, ViewState must be handled carefully at the page and control levels.
Comments
Post a Comment