找回密码
 加入
搜索
查看: 1409|回复: 3

[AU3基础] list列表怎么样才能实现右键创建ContextMenu

[复制链接]
发表于 2013-4-25 13:10:27 | 显示全部楼层 |阅读模式
如题,希望能有人帮下
发表于 2013-4-25 13:31:45 | 显示全部楼层

#include <GUIConstantsEx.au3>

Local $add, $clear, $mylist, $close, $msg
Local $MESSAGE = "The following buttons have been clicked"

GUICreate("My GUI list") ; will create a dialog box that when displayed is centered

$mylist = GUICtrlCreateList("buttons that have been clicked", 10, 32, 350, 97)
GUICtrlSetLimit(-1, 200) ; to limit horizontal scrolling
GUICtrlSetData(-1, $MESSAGE)
Local $buttoncontext = GUICtrlCreateContextMenu($mylist)
GUICtrlCreateMenuItem("About button", $buttoncontext)
GUICtrlCreateMenuItem("About button1", $buttoncontext)
GUICtrlCreateMenuItem("About button2", $buttoncontext)
GUICtrlCreateMenuItem("About button3", $buttoncontext)


GUISetState()

$msg = 0
While $msg <> $GUI_EVENT_CLOSE
        $msg = GUIGetMsg()
WEnd
 楼主| 发表于 2013-4-25 13:35:57 | 显示全部楼层
谢谢,问题解决了
发表于 2013-4-25 23:18:53 | 显示全部楼层
太牛了呵呵 不错 需要这个
您需要登录后才可以回帖 登录 | 加入

本版积分规则

QQ|手机版|小黑屋|AUTOIT CN ( 鲁ICP备19019924号-1 )谷歌 百度

GMT+8, 2024-11-15 10:08 , Processed in 0.107735 second(s), 23 queries .

Powered by Discuz! X3.5 Licensed

© 2001-2024 Discuz! Team.

快速回复 返回顶部 返回列表