Main Menu / Subform display question

If two subforms are visable at the same time on the Main Menu, what determines which subform is displayed on top? Is there a way to set this or change this in code? Any help would be greatly appreciated. Keith Reichert

First, note that the buttons on the menu are option buttons with the circle removed (BitmapPos property = None) and a border so that they look like command buttons. Note the Option Value property of each button & the SourceExpr. Now look at the code behind one of the buttons. When you click the button, it sets the SourceExpr variable to have the option value of that button. The OnValidate trigger then executes the ChangeSubMenu global function. Each subform control has been given a name and this global function switches the visible property on/off to make each one appear & disappear. In this way, the subforms are not actually layered so there is no bring to front/send to back stuff, it is just that only one is visible at any one time and you are simply looking straight through the rest of them. If you want to get to a particular subform for design purposes then that means you have to move/resize the subforms until you uncover the one that you want to mangle.

Would like to add that it is often more convenient to bring the subform to front (= make it visible), then press ctrl-F2 to enter the object designer directly. That’s for example also a handy way to see the ID of the (many) subforms. John

To JohnP: There’s no need to move or resize subforms when your are designing main menu form. You simply use menu commands “Format / Bring to Front” and “Format / Send to Back” to get access to needed subform. Edited by - Otto Dreyer on 6/28/00 1:39:02 PM

True, I so rarely need it that I’d forgotten about that. Thanks for reminding me.