Kyme 0 Report post Posted May 22, 2008 if i have two GUICreate for ex. $Menu1=GUICreate("",200,200,-1,-1,-1,BitOR(@SW_SHOW,$WS_EX_TOOLWINDOW)) $Menu2=GUICreate("",200,200,-1,-1,-1,BitOR(@SW_HIDE,$WS_EX_TOOLWINDOW)) when i start the script will show me $Main1 then if i press some buton it will show $Main2 how i can make it, if i press $Menu2 close("X") buton to dont close script only to close or hide $menu2.... i wait advices tnx Share this post Link to post Share on other sites
newbiescripter 0 Report post Posted May 22, 2008 Try search for OnAutoItExit() in the help file. Regards Share this post Link to post Share on other sites
Valuater 107 Report post Posted May 22, 2008 Maybe... #include<GUIConstantsEx.au3> #include<WindowsConstants.au3> $Menu1=GUICreate("",400,400,-1,-1,-1,$WS_EX_TOOLWINDOW) $Button = GUICtrlCreateButton("Show Menu 2", 30, 50, 100, 25) GUISetState() $Menu2=GUICreate("",200,200,-1,-1,-1,$WS_EX_TOOLWINDOW) GUISetState(@SW_HIDE) While 1 $msg = GUIGetMsg() If $msg = -3 Then If WinActive($Menu1) then Exit GUISetState(@SW_HIDE, $Menu2) EndIf If $msg = $Button Then GUISetState(@SW_SHOW, $Menu2) WEnd 8) Share this post Link to post Share on other sites
Kyme 0 Report post Posted May 22, 2008 ....that was really fast.....tnx Valuater..... I love this forum and ppl from here.... tnx again for help guys take cares Share this post Link to post Share on other sites
Valuater 107 Report post Posted May 22, 2008 Welcome 8) Share this post Link to post Share on other sites