ReDFlaG Posted February 13, 2014 Posted February 13, 2014 Hello all, When i change the name of a tab, the items that are holded into the tab disappear. i've found a workaround but it makes the GUI flicker: GUISetState(@SW_HIDE) then GUISetState(@SW_SHOW) Is there a clean way to do solve this issue ? Thanks Here 's an example of the issue: #include <Constants.au3> #include <Array.au3> #include <GuiTab.au3> #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> $mainwindow=GUICreate ('test',850,750,-1,-1,$WS_SIZEBOX+$WS_SYSMENU) $hTab = GUICtrlCreateTab(5, 10,800, 700) GUISetState() $Tab1= GUICtrlCreateTabItem("TAB ") GUICtrlCreateCheckbox("#",20,50,70,50) GUICtrlCreateCheckbox("#",20,100,70,50) GUICtrlCreateCheckbox("#",20,150,70,50) GUICtrlCreateCheckbox("#",20,200,70,50) GUICtrlCreateTabItem("") sleep(5000) _GUICtrlTab_SetItemText($hTab,0,"CHANGED") Do Until GUIGetMsg() = $GUI_EVENT_CLOSE GUIDelete()
Solution JohnOne Posted February 13, 2014 Solution Posted February 13, 2014 #include <Constants.au3> #include <Array.au3> #include <GuiTab.au3> #include <WinAPI.au3>;<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> $mainwindow = GUICreate('test', 850, 750, -1, -1, $WS_SIZEBOX + $WS_SYSMENU) $hTab = GUICtrlCreateTab(5, 10, 800, 700) GUISetState() $Tab1 = GUICtrlCreateTabItem("TAB ") GUICtrlCreateCheckbox("#", 20, 50, 70, 50) GUICtrlCreateCheckbox("#", 20, 100, 70, 50) GUICtrlCreateCheckbox("#", 20, 150, 70, 50) GUICtrlCreateCheckbox("#", 20, 200, 70, 50) GUICtrlCreateTabItem("") Sleep(5000) _GUICtrlTab_SetItemText($hTab, 0, "CHANGED") _WinAPI_RedrawWindow($mainwindow);<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< Do Until GUIGetMsg() = $GUI_EVENT_CLOSE GUIDelete() AutoIt Absolute Beginners Require a serial Pause Script Video Tutorials by Morthawt ipify Monkey's are, like, natures humans.
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