在GUI上創(chuàng)建一個標(biāo)簽頁控件項目。
GUICtrlCreateTabItem ( "文本" )
參數(shù)
| 文本 | 控件的文本。 |
返回值
| 成功: | 返回控件標(biāo)識符(控件ID)。 |
| 失敗: | 返回值為0。 |
注意
若要設(shè)置或修改控件的各種信息請查看 GUICtrlSet....
相關(guān)
GUICtrlSetState, GUIGetMsg
示例
#include <GUIConstants.au3>
GUICreate("我的 GUI 之Tab") ; 創(chuàng)建一個居中顯示的窗口
GUISetBkColor(0x00E0FFFF)
GUISetFont(9, 300)
$tab=GUICtrlCreateTab (10,10, 200,100)
$tab0=GUICtrlCreateTabitem ("tab0")
GUICtrlCreateLabel ("label0", 30,80,50,20)
$tab0OK=GUICtrlCreateButton ("OK0", 20,50,50,20)
$tab0input=GUICtrlCreateInput ("默認(rèn)文本", 80,50,70,20)
$tab1=GUICtrlCreateTabitem ( "tab----1")
GUICtrlCreateLabel ("label1", 30,80,50,20)
$tab1combo=GUICtrlCreateCombo ("", 20,50,60,40)
GUICtrlSetData(-1,"Trids|CyberSlug|Larry|Jon|Tylo", "Jon") ; 默認(rèn)是 Jon
$tab1OK=GUICtrlCreateButton ("OK1", 80,50,50,20)
$tab2=GUICtrlCreateTabitem ("tab2")
GUICtrlSetState(-1,$GUI_SHOW) ; 這個標(biāo)簽將先顯示
GUICtrlCreateLabel ("label2", 30,80,50,20)
$tab2OK=GUICtrlCreateButton ("OK2", 140,50,50)
GUICtrlCreateTabitem ("") ; 結(jié)束標(biāo)簽項的定義
GUICtrlCreateLabel ("label3", 20,130,50,20)
GUISetState ()
; 運行腳本直到窗口被關(guān)閉
While 1
$msg = GUIGetMsg()
If $msg = $GUI_EVENT_CLOSE Then ExitLoop
Wend
青岛市| 拉萨市| 保亭| 枣强县| 宿州市| 揭东县| 波密县| 巴林右旗| 精河县| 凌源市| 蚌埠市| 丽江市| 舟曲县| 西和县| 兰坪| 永顺县| 锦州市| 甘谷县| 洛南县| 来宾市| 西峡县| 潞城市| 磴口县| 梧州市| 玉林市| 乐山市| 抚顺市| 桐梓县| 吴江市| 咸丰县| 英吉沙县| 崇义县| 吴堡县| 长宁区| 广河县| 黑河市| 山西省| 玛多县| 贵溪市| 揭西县| 太原市|