Minimize ViewState with TreeView

人盡茶涼 提交于 2019-12-06 09:40:26

here is a wonderful way to just get rid of viewstate from being sent over wire for each post-back. basically, it stores the complete viewstate as a session variable on the server and only transfers the identifier in the viewstate field.

compression will save you little bit in terms of bandwidth whereas putting getting viewstate out of the page will have quite dramatic performance improvement

the following articles explains several techniques with performance measurement metrics as well eggheadcafe

Eoin Campbell

Well you could just stored ViewState in Session and prevent it from going down to the Client at all. Then it'll just be controlstate that's sent up and down which should reduce the page size pretty dramatically...

protected override PageStatePersister PageStatePersister
{
    get
    {
        return new SessionPageStatePersister(this);
    }
}

More info @ this question

Keeping ViewState in SessionPageStatePersister

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!