Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

view state in usercontrols

Tags:

asp.net

Is it necessary to reload the viewstate of usercontrols during postback? I want to know in which case viewstate is set by default.

like image 245
Viren Avatar asked Mar 09 '26 07:03

Viren


1 Answers

no it's not necessary that everytime view state of a usercontrol or webcontrol will be set. it can be controled during page cycle if viewstate properties of a control set =false then it will not set while page is postback. autopostback.

you can also control viewstate properties of a usercontrol and webcontrol in pre_int stage of life cycle. you can also off tracing of view state in pre_int stage of life cycle. for more information link text

like image 123
Nishant Kumar Avatar answered Mar 12 '26 01:03

Nishant Kumar