Advertisement
YasserKhalil2019

WiseOwl

Mar 23rd, 2021
73
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.47 KB | None | 0 0
  1. Private cd As Selenium.ChromeDriver
  2.  
  3. Sub DownloadWithHeadless()
  4. Dim lnk As Selenium.WebElement
  5. Set cd = New Selenium.ChromeDriver
  6. With cd
  7. .SetPreference "download.default_directory", ThisWorkbook.Path & "\"
  8. .AddArgument "--headless"
  9. .Start
  10. .Get "https://www.wiseowl.co.uk/vba-macros/videos/vba-scrape-websites/web-scraping-selenium-chrome/"
  11. Set lnk = .FindElementByLinkText("here")
  12. lnk.Click
  13. End With
  14. End Sub
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement