Difference between Control's ViewState and ControlState?

E

Edward

I am reading MSDN doc about Control's ViewState and ControlState. I got
myself quite puzzled. I see that the Control class has four virtual
functions:

LoadControlState
LoadViewState
SaveControlState
SaveViewState

But a Control has only ViewState property but no ControlState.

Can anyone clarify on the difference between Control's ViewState and
ControlStae?

Thanks.
 
M

Manish

Hi,

you can refer to following two links for detailed information about the
Control state and ViewState of the control. You can disable the Viewstate of
the control but not the Controlstate. controlstate is also stored in the
Hidden Field in HTML under_viewstate.

Behavioral state for a control should be kept in control state, and UI state
(its contents) should be kept in view state.

http://www.pluralsight.com/blogs/fritz/archive/2004/07/01/472.aspx

http://msdn.microsoft.com/en-us/library/1whwt1k7.aspx

Regards,
Manish
www.ComponentOne.com
 
E

Edward

Thanks.
Hi,

you can refer to following two links for detailed information about the
Control state and ViewState of the control. You can disable the Viewstate of
the control but not the Controlstate. controlstate is also stored in the
Hidden Field in HTML under_viewstate.

Behavioral state for a control should be kept in control state, and UI state
(its contents) should be kept in view state.

http://www.pluralsight.com/blogs/fritz/archive/2004/07/01/472.aspx

http://msdn.microsoft.com/en-us/library/1whwt1k7.aspx

Regards,
Manish
www.ComponentOne.com
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,007
Latest member
obedient dusk

Latest Threads

Top