查看全部评分
举报
$Dir = @WindowsDir ;定义要打开的文件夹 RunWait('explorer ' & $Dir) $a = _GetCWHandle(@WindowsDir) MsgBox(0, '获取到的句柄:' & $a, '请在打开的文件夹中进行打开子文件夹或返回上级目录的操作,之后再点击确定') MsgBox(0, '当前打开的文件夹:', ControlGetText($a, '', 'Edit1')) Func _GetCWHandle($Dir) Local $all, $i, $CWHandle While 1 Sleep(1) $all = WinList('[CLASS:CabinetWClass]') For $i = 1 To $all[0][0] If ControlGetText($all[$i][1], '', 'Edit1') = $Dir Then $CWHandle = $all[$i][1] ExitLoop 2 EndIf Next WEnd Return $CWHandle EndFunc ;==>_GetCWHandle
本版积分规则 发表回复 回帖后跳转到最后一页
|手机版|小黑屋|AUTOIT CN ( 鲁ICP备19019924号-1 )谷歌 百度
GMT+8, 2026-6-7 00:08 , Processed in 0.219722 second(s), 23 queries .
Powered by Discuz! X3.5 Licensed
© 2001-2026 Discuz! Team.