Rodger Posted December 7, 2010 Share Posted December 7, 2010 (edited) expandcollapse popup#include <GuiTab.au3> #include <GuiEdit.au3> #include <GuiTreeView.au3> #include <GuiListView.au3> #include <GuiButton.au3> #include <WindowsConstants.au3> #include <GUIConstants.au3> #include <GUIConstantsEx.au3> #include <Array.au3> Global $main_GUI,$ok_button,$cancel_button ; This window has 2 ok/cancel-buttons $main_GUI = GUICreate("TAB in TAB",260,250,-1,-1) $ok_button = GUICtrlCreateButton("OK",40,220,70,20) $cancel_button = GUICtrlCreateButton("Cancel",150,220,70,20) ; Create the first child window that is implemented into the main GUI $child1 = GUICreate("",230,170,15,35,BitOr($WS_CHILD,$WS_TABSTOP),-1,$main_GUI) $child_tab = GUICtrlCreateTab(10,10,210,150) $child11tab = GUICtrlCreateTabItem("1") $child12tab = GUICtrlCreateTabItem("2") GUICtrlCreateTabItem("") GUISetState() ; Create the second child window that is implemented into the main GUI $child2 = GUICreate("",230,170,15,35,BitOr($WS_CHILD,$WS_TABSTOP),-1,$main_GUI) $listview2 = GUICtrlCreateListView("Col1|Col2",10,10,210,150,-1,$WS_EX_CLIENTEDGE) GUICtrlCreateListViewItem("ItemLong1|ItemLong12", $listview2) GUICtrlCreateListViewItem("ItemLong2|Item22", $listview2) ; Switch back the main GUI and create the tabs GUISwitch($main_GUI) $main_tab = GUICtrlCreateTab(10,10,240,200) $child1tab = GUICtrlCreateTabItem("Child1") $child2tab = GUICtrlCreateTabItem("Child2") GUICtrlCreateTabItem("") GUISetState() While 1 $msg = GUIGetMsg(1) Switch $msg[0] Case $GUI_EVENT_CLOSE, $cancel_button ExitLoop Case $main_tab Switch GUICtrlRead($main_tab) Case 0 GUISetState(@SW_HIDE,$child2) GUISetState(@SW_SHOW,$child1) Case 1 GUISetState(@SW_HIDE,$child1) GUISetState(@SW_SHOW,$child2) EndSwitch Case $child_tab Switch GUICtrlRead($child_tab) Case 0 ConsoleWrite("0" & @CRLF) Case 1 ConsoleWrite("1" & @CRLF) EndSwitch EndSwitch WEnd Hello, I found the above example of a Tab in a Tab. I like to know if there is an easy way to get another tab in the child_tab; so first you have tab "Child1" | "Child2" then tab "1" | tab "2" under tab "Child1" then eg. tab "11" | tab "22" under tab "1" I tried to make tab "1" as some kind of a parent tab but I didn't succeed. Is there an easy way to accomplish this? Thnx, Rodger Edited December 7, 2010 by Rodger Link to comment Share on other sites More sharing options...
Moderators Melba23 Posted December 9, 2010 Moderators Share Posted December 9, 2010 Rodger,Is there an easy way to accomplish this?I am afraid not - one tab control per GUI, so using child windows is the only way to go if you want multiple tabs. M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Link to comment Share on other sites More sharing options...
ReFran Posted December 9, 2010 Share Posted December 9, 2010 (edited) Hi, maybe using "TCS_Multiline" gives you already what you want. HTH, Reinhard Edited December 9, 2010 by ReFran Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now