#include <ButtonConstants.au3>
#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>
$Form1 = GUICreate("Form1", 269, 141, 372, 253)
$Button1 = GUICtrlCreateButton("Button1", 40, 56, 75, 25, 0)
$Button2 = GUICtrlCreateButton("Button2", 136, 56, 75, 25, 0)
GUISetState(@SW_SHOW)
While 1
$nMsg = GUIGetMsg()
Switch $nMsg
Case $GUI_EVENT_CLOSE
Exit
Case $Button1
manager()
EndSwitch
WEnd
Func manager()
$Form2 = GUICreate("Form2", 239, 100, 372, 253)
$Button1 = GUICtrlCreateButton("Button1", 40, 56, 75, 25, 0)
$Button2 = GUICtrlCreateButton("Button2", 136, 56, 75, 25, 0)
GUISetState(@SW_SHOW)
While 1
$nMsg = GUIGetMsg()
Switch $nMsg
Case $GUI_EVENT_CLOSE
GUIDelete($Form2)
WinActivate("Form2")
GUISetState(@SW_ENABLE, $Form1)
ExitLoop
EndSwitch
WEnd
EndFunc
简单点说就是在父窗口上点出子窗口来
然后子窗口在最顶层 而且不能操作父窗口 必须把子窗口关掉才能操作父窗口
怎么实现? 因为做的软件需要这个功能 请大家帮忙
[ 本帖最后由 kryiran 于 2008-8-21 21:31 编辑 ] |