Electron microscopy
 
Automatically Review, Scroll, Click Webpage and Its Link
- Integrated Circuits -
- An Online Book -
Integrated Circuits                                                                                   http://www.globalsino.com/ICs/        


Chapter/Index: Introduction | A | B | C | D | E | F | G | H | I | J | K | L | M | N | O | P | Q | R | S | T | U | V | W | X | Y | Z | Appendix

=================================================================================

==================================================

        Possible error message when running the chromedriver.exe >> DeprecationWarning: executable_path has been deprecated, please pass in a Service object
        i) To Solve DeprecationWarning: executable_path has been deprecated, please pass in a Service object Error Here executable_path is deprecated you have to use an instance of the Service() class as follows. s = Service('C:/Users/…/chromedriver.exe') and then driver = webdriver.Chrome(service=s) Now, Your error must be solved.
        ii) To Solve DeprecationWarning: executable_path has been deprecated, please pass in a Service object Error Here executable_path is deprecated you have to use an instance of the Service() class as follows. s = Service('C:/Users/…/chromedriver.exe') and then driver = webdriver.Chrome(service=s) Now, Your error must be solved.
        The code will also be changed to:
             from selenium import webdriver
             from selenium.webdriver.chrome.service import Service # Adding
             ser = Service(r"C:\...\chromedriver.exe") # Adding
             op = webdriver.ChromeOptions() # Adding, but it can be removed
             s = webdriver.Chrome(service=ser, options=op) # Adding
             s = webdriver.Chrome(service=ser) # Adding, but removed "options=op"

==================================================

Set maximum window size, scroll down the webpage, find if there is a link with a specific text or not, get the actual link and then click it, closes the current browser window, quit from the browser driver: Code:
         Automatically Review, Scroll, Click Webpage and Its Link

 

 

=================================================================================