RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
TPage.ReadState Method

Prepares the control for having its properties assigned values from a stream.

Pascal
procedure ReadState(Reader: TReader); override;
C++
virtual __fastcall ReadState(TReader Reader);

Override ReadState to change the preparations the control makes as it readies itself to have its property values assigned from a stream. For example, a control might destroy temporary internal data structures or objects before new instances are loaded from the stream. Be sure to include a call to the inherited method when overriding ReadState. 

As implemented in TWinControl, ReadState disables control alignment until all the child controls have been read from the stream, calls the inherited ReadState method, and re-enables the alignment of all the controls. The method then builds the tab order list of controls and synchronizes its visibility with that of its parent control. 

 

Copyright(C) 2009 Embarcadero Technologies, Inc. All Rights Reserved.
What do you think about this topic? Send feedback!