I am trying to click on an element that will download an Excel report. I am correctly locating the element using the below code. However, I am unable to click it by using .click or Select().
driver.find_element_by_xpath(element)
-.click returns "selenium.common.exceptions.ElementNotInteractableException: Message: element not interactable"
-Select() returns "selenium.common.exceptions.UnexpectedTagNameException: Message: Select only works on elements, not on "
How do I click on the element? The element looks like this when I inspect it:
<a href="#" onclick="tablesToExcel(['summary','table1'], ['Report Profit'], 'myfile.xls')">
<img src="/portalDispensary/vendors/tableExport/icon/xls.png" width="24px" class="mrx">
"Export to Excel"
</a>