Link to home
Start Free TrialLog in
Avatar of shawn857
shawn857

asked on

How to move all controls (quickly) from one TabSheet to another

Hi, I have a form with 2 TPageControls on it. The 1st one has 3 TabSheets, and on the 2nd of these Tabsheets, I have placed another TPageControl that contains 2 additional TabSheets. I need to move all controls (and keep them intact) that were on the 1st PageControl and 1st TabSheet, to the 2nd PageControl/1st TabSheet. Is the only way to cut and paste each individual control, or is there a slicker way to do it quickly?

Thanks!
    Shawn
ASKER CERTIFIED SOLUTION
Avatar of Thommy
Thommy
Flag of Germany image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of ste5an
Or you may use a view-based UI approach. Normally each page of a Tab is a unit. So create a view for each page, then you only need to change the assignement of the view to the tab. A view in this context can be a frame or a form.
In Structure view (where object are shown as parent/child in treeview) find your tabsheet and select all child components holding shift. Then in popup menu select Edit/Cut - find destination tabsheet in Structure view and do paste.
Avatar of shawn857
shawn857

ASKER

Thanks all. Sinisa, after I selected all my components and chose Edit/Cut, there was no "paste" option in my destination TabSheet under the "Edit" popup menu.

Shawn
Strange, try to select in design view same tabsheet and use edit/paste there.
Thanks to all who replied. This was the most straightforward solution for me.

Cheers
   Shawn