How do I change the order of controls on a form?

Knowledge Base Article # Q200091

Read Prior Article Read Next Article
Summary How do you make a control show on another control on a form
  
Login to rate article
The form controls are drawn according to the order of the Form.Controls where 0 is drawn first and 1 is on top of 0, etc. This is sometimes reffered to as ZOrder of controls.

At design-time, you can change the order of controls at design time using the Tab Order command (Edit, Arrange, Tab Order) or by dragging the control in the Controls drop down list at the form editor.

At run-time, you can use the following code to change the ZOrder using the following code:

img1.ZOrder(aWindowZOrderTop)


will draw the img1 control on top of all controls. If you want img1 on top of img3, do the following:

img3.ZOrder(aWindowZOrderTop)
img1.ZOrder(aWindowZOrderTop)


Article Date 6/16/2008
Keywords ATEasy, Form, ZOrder, Tab Order


Login to rate article

Read Prior Article Read Next Article
>