AdlibRegister("shuaxin", 5 * 50 * 1000)
shuaxin()
While 1
$msg = GUIGetMsg()
Switch $msg
Case -3
Exit
Case $msg = $Button_01 ;刷新
_GUICtrlListView_DeleteAllItems($Lv)
_GUICtrlListView_EndUpdate($Lv)
shuaxin()
_GUICtrlListView_EndUpdate($Lv)
EndSwitch
WEnd
Func shuaxin()
$isource = FileRead("main.txt")
$sRegExp1 = "(?s)\<a\htitle\=\'(\S*)\'.*?\id\=(\d+)"
$Test1 = StringRegExp($isource, $sRegExp1, 3)
For $i = 0 To UBound($Test1) - 1 Step 2
GUICtrlCreateListViewItem($Test1[$i + 1] & "|" & $Test1[$i], $Lv)
Next
EndFunc ;==>shuaxin
|