开发者

onclick event activation

I am sending web requests to a site and getting the responsestream and would like to perform the button click programatically, here is the tag for the event:

 <a href="#" onclick="getResults('app开发者_运维知识库le', 2); return false;" id="nextLink" class="next button_grey_sm">Next &raquo;</a>

any ideas appreciated?


I used a web browser control... it might not have been the best approach since I don't know what page it's on, but here's my code:

Dim wb As WebBrowser = New WebBrowser
wb.Navigate("http://www.mydomain.com")
wb.Document.GetElementsByTagName("a")(2).InvokeMember("click")

This basically "clicks" the 3rd (the array is 0-based) tag on the current page.

HTH

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜