RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
TWinControl.SetZOrder Method

Moves the control to the top or bottom of the parent control's (or screen's) list of TWinControl controls.

Pascal
procedure SetZOrder(TopMost: Boolean); override;
C++
virtual __fastcall SetZOrder(Boolean TopMost);

Use SetZOrder to rearrange overlapping controls within a parent control or (if the control has no parent) overlapping windows on the screen. If the TopMost parameter is true, the control becomes the top control; otherwise, it becomes the bottom control.  

TWinControl controls always stack on top of other controls, regardless of the Z order. 

After changing the order, SetZOrder invalidates the control to ensure repainting to reflect the new order. 

 

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