I'm trying to click on a report inside an accordian element.
Ive tried various methods to identify the element but nothing i tried worked.
With XPath and Id I get the following error message:
OpenQA.Selenium.ElementNotInteractableException: 'element not interactable'
This is the code I've tried.
static IWebDriver driver = new ChromeDriver();
static IWebElement element;
driver.FindElement(By.XPath("//*[@id=\"ContentPlaceHolder1_ReportCreator1_DataListReports_3_LinkButtonReport_0\"]")).Click();
driver.FindElement(By.Id("ContentPlaceHolder1_ReportCreator1_DataListReports_3_LinkButtonReport_0")).Click();
This is the HTML inside the accordion that I'm targeting,
<a id="ContentPlaceHolder1_ReportCreator1_DataListReports_3_LinkButtonReport_0" class="ReportImg" href="javascript:__doPostBack ('ctl00$ContentPlaceHolder1$ReportCreator1$AccordionReportList_Pane_3_content$DataListReports$ctl00$LinkButtonReport','')">All Assessments</a>