Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > Optimizing ViewState

Reply
Thread Tools

Optimizing ViewState

 
 
Ben Fidge
Guest
Posts: n/a
 
      02-17-2005
Does anyone know any tricks for reducing the size of the ViewState?

Kind regards

Ben



 
Reply With Quote
 
 
 
 
Karl Seguin
Guest
Posts: n/a
 
      02-17-2005
Ben,
The question is on the vague side. Turn on tracing, see what's using
viewstate and see if you can make it work without. if your page doesn't
postback, you can turn viewstate off at the page level.

Check out Scott Guthrie's deck on performance
http://scottgu.com/PerformanceEurope.zip it touches briefly on viewstate.

A nice compression module can help mitigate the performance issues around
round-triping large viewstate
(http://www.blowery.org/code/HttpCompressionModule.html)

Karl

--
MY ASP.Net tutorials
http://www.openmymind.net/


"Ben Fidge" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> Does anyone know any tricks for reducing the size of the ViewState?
>
> Kind regards
>
> Ben
>
>
>



 
Reply With Quote
 
 
 
 
Ben Fidge
Guest
Posts: n/a
 
      02-17-2005
Thanks Karl,

I'll have a look.

Ben


"Karl Seguin" <karl REMOVE @ REMOVE openmymind REMOVEMETOO . ANDME net>
wrote in message news:(E-Mail Removed)...
> Ben,
> The question is on the vague side. Turn on tracing, see what's using
> viewstate and see if you can make it work without. if your page doesn't
> postback, you can turn viewstate off at the page level.
>
> Check out Scott Guthrie's deck on performance
> http://scottgu.com/PerformanceEurope.zip it touches briefly on viewstate.
>
> A nice compression module can help mitigate the performance issues around
> round-triping large viewstate
> (http://www.blowery.org/code/HttpCompressionModule.html)
>
> Karl
>
> --
> MY ASP.Net tutorials
> http://www.openmymind.net/
>
>
> "Ben Fidge" <(E-Mail Removed)> wrote in message
> news:(E-Mail Removed)...
>> Does anyone know any tricks for reducing the size of the ViewState?
>>
>> Kind regards
>>
>> Ben
>>
>>
>>

>
>



 
Reply With Quote
 
=?Utf-8?B?U2hhdW4=?=
Guest
Posts: n/a
 
      02-18-2005
Things that will considerably reduce your viewstate size :-

1) Disable viewstate for those controls that are going to get populated
everytime a page loads.
2) Disable viewstate for the page if the page does not postback to itself.
3) Viewstate can store a type that either is serializable or has a
TypeConverter defined for it can be persisted in ViewState. However, types
that are only serializable are slower and generate a much LARGER ViewState.
Hence reduce the number of only serializable types.


Best of Luck



"Ben Fidge" wrote:

> Does anyone know any tricks for reducing the size of the ViewState?
>
> Kind regards
>
> Ben
>
>
>
>

 
Reply With Quote
 
=?Utf-8?B?U2hhdW4=?=
Guest
Posts: n/a
 
      02-18-2005
hey one more site to help you with compressing the viewstate.

http://www.mostlylucid.co.uk/archive...01/03/694.aspx


"Shaun" wrote:

> Things that will considerably reduce your viewstate size :-
>
> 1) Disable viewstate for those controls that are going to get populated
> everytime a page loads.
> 2) Disable viewstate for the page if the page does not postback to itself.
> 3) Viewstate can store a type that either is serializable or has a
> TypeConverter defined for it can be persisted in ViewState. However, types
> that are only serializable are slower and generate a much LARGER ViewState.
> Hence reduce the number of only serializable types.
>
>
> Best of Luck
>
>
>
> "Ben Fidge" wrote:
>
> > Does anyone know any tricks for reducing the size of the ViewState?
> >
> > Kind regards
> >
> > Ben
> >
> >
> >
> >

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Problems with ViewState: "function 'ViewState.get_Item' evaluated and returned null" Steph ASP .Net 2 05-11-2011 02:35 PM
Errors: Failed to load viewstate. & Validation of viewstate MAC failed. sck10 ASP .Net 6 09-01-2006 05:59 PM
Loading usercontrols, viewstate problem, slighly different from all others "viewstate uc problems" please help... ujjc001 ASP .Net 0 07-27-2005 01:52 PM
Viewstate errors... how do I get viewstate working? mark ASP .Net Building Controls 0 02-20-2004 02:17 PM
Corrupted ViewState (Yes, another issue concerning viewstate) Ben Rush ASP .Net 2 12-05-2003 04:17 PM



Advertisments