Kyme Posted May 22, 2008 Share 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 Link to comment Share on other sites More sharing options...
newbiescripter Posted May 22, 2008 Share Posted May 22, 2008 Try search for OnAutoItExit() in the help file. Regards Link to comment Share on other sites More sharing options...
Valuater Posted May 22, 2008 Share 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) Link to comment Share on other sites More sharing options...
Kyme Posted May 22, 2008 Author Share 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 Link to comment Share on other sites More sharing options...
Valuater Posted May 22, 2008 Share Posted May 22, 2008 Welcome 8) 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