SysTreeview32vb怎么读取systreeview中选中节点文本名称
发布网友
发布时间:2024-10-13 17:59
我来回答
共1个回答
热心网友
时间:2024-11-24 17:29
#include <GuiTreeView.au3>
$Win="番茄花园 Windows 主题资源包 2.7.0.0 安装 ";;窗口名称
If Not WinExists($Win) Then
MsgBox(0,"","不存在的窗口对像.")
Exit
EndIf
$hWnd=ControlGetHandle($Win,"","[id:1032]");;,[id:1032]控件句柄
Local $sItem
$hStart = _GUICtrlTreeView_GetFirstItem($hWnd)
MsgBox(0,"","全部取消 .")
$fCheck = False
While $hStart <> 0x00000000
_GUICtrlTreeView_SetChecked($hWnd,$hStart,$fCheck)
$hStart = _GUICtrlTreeView_GetNext($hWnd, $hStart)
WEnd
MsgBox(0,"","全部选择.")
$hStart = _GUICtrlTreeView_GetFirstItem($hWnd)
$fCheck = True
While $hStart <> 0x00000000
_GUICtrlTreeView_SetChecked($hWnd,$hStart,$fCheck)
$hStart = _GUICtrlTreeView_GetNext($hWnd, $hStart)
WEnd
Exit