Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
htm text find next ..
#2
Macro Macro2433
Code:
Copy      Help
out

;this macro clicks all span elements containing text "apple"

lpstr keyword = "apple"
int IEFrame = win("" "IEFrame")
Htm eSpan eParent
eParent=htm("BODY" "" "" IEFrame)
MSHTML.IHTMLElement2 e2=+eParent.el
foreach eSpan.el e2.getElementsByTagName("span")
,str s=eSpan.Text
,out s
,if find(s keyword 0 1)>=0
,,out "keyword found"
,,;eSpan.Click
,,eSpan.Mouse(1)
,,wait 0.5


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)