Managing overlapping controls

At one place in my app, I want in effect to replace one control with another. For example: I have a popupmenu that is populated with a list of nicknames. The user can select one and the app then displays information about that nickname.

The user can also click a “new” button to create a new nickname. In that case, I want to replace the popupmenu with a textfield into which the user will type the name of the new nickname. So far I’ve been managing just by layering the controls almost but not quite on top of each other. I can then swap the visibility of the two controls to go from one to the other. I discovered that a control completely hidden by another seems to get grouped with it, somehow.

What is the best solution here? Should I move all such controls out of the window in the IDE, and then at runtime modify their Left property to bring them back on? What do other people do here?

Look at container controls. You place your controls on a CC and then you can hide or show container controls as needed. I have several container controls layered on one of my apps and I can show or hide them smoothly without flicker.

In the past in a desktop app I’ve used a page panel to do this.

+1 for page panel.

Thanks. Could use a page panel - in fact I’m already doing that elsewhere in the app.