testrow=Browser("testip").Page("【testpage").Frame("mainFrame0_2").WebTable("testtable").GetRowWithCellText("a111230122")
print "order list id"&cstr(testrow)
Set des=description.Create()
des("micclass").value="WebButton"
'des("xpath").value="/html/body/div/div[2]/div[3]/table/tbody/tr[2]/td[11]/input"
set alist=Browser("testip").Page("【testpage").ChildObjects(des)
b=alist.count
print b
counted=0
For i=0 to b-1
If alist(i).getroproperty("value")="购买" then
counted=counted+1
If counted=(testrow-2) Then
alist(i).click
End If
' print "test id:"&cstr(counted)
end if
Next
QTP的那些事--采用DOM,描述性编程获取指定的对象
最新推荐文章于 2020-07-11 23:06:36 发布