Can we get all the links on the page Using Watin
-
30-09-2019 - |
Question
Is is possible to get all the Links on the page using WatiN. I found it pretty easy in html agility pack but i have to use WatiN.
Solution
you can use Browser.Links
methods
using(Browser browser = new IE("http://www.sp4ce.net"))
{
foreach(Link link in browser.Links)
{
Console.WriteLine(link);
}
}
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow