病毒专收员 发表于 2010-12-20 09:39:12

请教如何遍历ListView 内容,如何取得 ListView 有多少行内容?[已解决]

本帖最后由 病毒专收员 于 2010-12-20 11:09 编辑

#include <GUIConstantsEx.au3>
#include <ListViewConstants.au3>
#include <WindowsConstants.au3>
#Region ### START Koda GUI section ### Form=
$Form1 = GUICreate("Form1", 623, 449, 192, 114)
$ListView1 = GUICtrlCreateListView("test", 8, 8, 602, 430)
GUICtrlSendMsg(-1, $LVM_SETCOLUMNWIDTH, 0, 50)
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###
For $i = 0 To 10 Step + 1
        GUICtrlCreateListViewItem ( "文本"&$i, $ListView1 )
Next
While 1
        $nMsg = GUIGetMsg()
        Switch $nMsg
                Case $GUI_EVENT_CLOSE
                        Exit

        EndSwitch
WEnd
请教如何 遍历 ListView 内的内容?
如何取得 ListView内有多少行内容?
如何取得 ListView内某一条内容在多少行?

水木子 发表于 2010-12-20 09:43:42

本帖最后由 水木子 于 2010-12-20 09:46 编辑

_GUICtrlListView_GetItemCount;获取项目数量
_GUICtrlListView_FindInText ;搜索包含指定文本的项目,这方面的函数有多个,楼主可以去帮助文档看看。

病毒专收员 发表于 2010-12-20 11:06:31

回复 2# 水木子


   恩,3Q~~

49666684 发表于 2011-11-29 11:35:41

不错,就想找这东西.

fjrti 发表于 2014-5-3 10:54:30

这个就是我想要的,谢谢了
页: [1]
查看完整版本: 请教如何遍历ListView 内容,如何取得 ListView 有多少行内容?[已解决]