javascript - How to invoke Click using HTML AGILITY PACK - Stack Overflow

In WebBrowser( WEBFORMS) we can i InvokeMember("click") when we parse an HTML.How can we do

In WebBrowser( WEBFORMS) we can i InvokeMember("click") when we parse an HTML. How can we do this using HTML AGILITY PACK .

<a id="ctl0_CONTENU_PAGE_resultSearch_PagerTop_ctl2" href="javascript:;//ctl0_CONTENU_PAGE_resultSearch_PagerTop_ctl2">

In WebBrowser( WEBFORMS) we can i InvokeMember("click") when we parse an HTML. How can we do this using HTML AGILITY PACK .

<a id="ctl0_CONTENU_PAGE_resultSearch_PagerTop_ctl2" href="javascript:;//ctl0_CONTENU_PAGE_resultSearch_PagerTop_ctl2">

How can i use HTTP REQUEST when we have a javascript in Href.

Share Improve this question edited Apr 27, 2017 at 13:54 Amrani asked Apr 27, 2017 at 13:30 AmraniAmrani 591 silver badge8 bronze badges
Add a ment  | 

2 Answers 2

Reset to default 4

No htmlagiliypack is not a html rendering engine you cannot invoke a click event . It 's just a parsing tool
use Webbrowser or selenium webdriver if you want

HtmlAgilityPack is only used to parse HTML and it doesn't support invoking events.

To invoke events you could use WebClient to send HTTP Request or Selenium.

For Selenium you could check this answer here: https://stackoverflow./a/34244583/7827699

For How to send Http Requests using WebClient: https://msdn.microsoft./en-us/library/system.webclient(v=vs.110).aspx

发布者:admin,转转请注明出处:http://www.yc00.com/questions/1745180738a4615406.html

相关推荐

发表回复

评论列表(0条)

  • 暂无评论

联系我们

400-800-8888

在线咨询: QQ交谈

邮件:admin@example.com

工作时间:周一至周五,9:30-18:30,节假日休息

关注微信