Advertisement
Guest User

Untitled

a guest
Dec 12th, 2018
88
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 0.87 KB | None | 0 0
  1. //Начало кода, входные данные
  2. IZennoTable Table_S = project.Tables["Domashka"];
  3. HtmlElement ShowMore = null;
  4. HtmlElement ShowMore1 = null;
  5.  
  6. //Переходим на сайт и ждем загрузку
  7. instance.ActiveTab.Navigate("https://kupidonia.ru/spisok/polnyj-spisok-muzhskih-imen", "");
  8. instance.ActiveTab.WaitDownloading();
  9.  
  10. //Поехали нажимать "Показать еще", пока не пропадет
  11. ShowMore = instance.ActiveTab.FindElementByAttribute("a", "innertext", "Показать еще", "regexp", 0);
  12. ShowMore1 = instance.ActiveTab.FindElementByAttribute("a", "style", "display: none;", "regexp", 0);
  13. string Done = ShowMore1.GetAttribute("style");
  14. do {
  15.     ShowMore.RiseEvent("click", "Full");
  16.     instance.ActiveTab.WaitDownloading();
  17.     System.Threading.Thread.Sleep(200);
  18. }
  19. while (!ShowMore1.IsVoid);
  20. return "Ok";
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement