切换 GUI 函数的当前窗口.
GUISwitch ( 句柄 [, 标签项目ID] )
句柄 | 切换为当前窗口的句柄. |
标签项目ID | [可选参数] 被选中标签项目的控件标识符. |
成功: | 返回上一个"当前"窗口的句柄. |
失败: | 返回空句柄. |
#include <GUIConstantsEx.au3>
Example()
Func Example()
Local
$parent1,
$parent2,
$TabItem ,
$msg
$parent1 = GUICreate("父窗
1")
GUICtrlCreateTab(10, 10)
$TabItem = GUICtrlCreateTabItem
("标签 1")
GUICtrlCreateTabItem ("标签 2")
GUICtrlCreateTabItem ("")
$parent2 = GUICreate("父窗
2", -1,
-1, 100,
100)
GUISwitch($parent2)
GUISetState()
Do
$msg = GUIGetMsg()
Until
$msg = $GUI_EVENT_CLOSE
GUISwitch($parent1, $TabItem )
GUICtrlCreateButton("确定",
50, 50, 50)
GUICtrlCreateTabItem ("")
GUISetState(@SW_SHOW, $parent1)
Do
$msg = GUIGetMsg()
Until
$msg = $GUI_EVENT_CLOSE
EndFunc ;==>Example
provider with jb51.net (unicode) |