1

enter image description here I'm making a bot, however, it doesn't click the download button at the end of the site. It was for him to click and generate a PDF report, but it doesn't work

I've done it, but it doesn't work

browser.find_element_by_xpath('//*[@id="inibe"]/font]').click()

In this HTML code is the href

 browser.find_element_by_xpath('/html/body/table/tbody/tr[9]/td/a/font').click()

This is what the mouse selector points to. But anyway, it doesn't work, it returns an error. Does anyone have any ideas?

pyahri
  • 27
  • 6
  • Can you add the text of the error and the HTML code of the button? – Sayyor Y Sep 10 '20 at 01:13
  • What error message you are getting? Share the HTML of the table row element. – supputuri Sep 10 '20 at 01:29
  • 1
    show in question minimal working code with real URL so we could run it. And put in question full error message. – furas Sep 10 '20 at 02:23
  • In [1]: browser.find_element_by_xpath('//*[@id="inibe"]/font').click() --------------------------------------------------------------------------- NoSuchElementException Traceback (most recent call last) in ----> 1 browser.find_element_by_xpath('//*[@id="inibe"]/font').click() – pyahri Sep 10 '20 at 18:47
  • --> 242 raise exception_class(message, screen, stacktrace) 243 244 def _value_or_default(self, obj, key, default): NoSuchElementException: Message: no such element: Unable to locate element: {"method":"xpath","selector":"//*[@id="inibe"]/font"} (Session info: chrome=85.0.4183.83) – pyahri Sep 10 '20 at 18:47
  • I can't send the URL for testing because I need to log into a customer's profile – pyahri Sep 10 '20 at 18:48

0 Answers0