本帖最后由 veket_linux 于 2012-11-19 19:10 编辑
成功了
#include <WinAPI.au3>
#include <GuiComboBox.au3>
$hGUI = GUICreate("test", 300, 250, -1, -1)
$hCombo = _GUICtrlComboBox_Create($hGUI, "", 40, 60, 120, 26)
GUISetState()
MyComboBoxSetAllItem($hCombo, "百度|google|AutoIt中文论坛")
Do
Until GUIGetMsg() = -3
Func MyComboBoxSetAllItem($hWnd, $items_string)
If $items_string <> "" Then
Local $items = StringSplit($items_string, "|")
Local $i
For $i = 1 To $items[0]
_SendMessage($hWnd, $CB_ADDSTRING, 0, $items[$i], 0, "wparam", "wstr")
Next
EndIf
EndFunc
没有枪... 没有炮 ... 我们自己来造..... |