0

Code trials:

chrome[row_index].FindElementByXPath("//*[@id=\"app\"]/div/div[1]/div[2]/div[3]/div[2]/div/button").Submit();

and

chrome[row_index].FindElementByXPath("//*[@id=\"app\"]/div/div[1]/div[2]/div[3]/div[2]/div/button").Click();

This is Error Message:

An exception of type 'OpenQA.Selenium.ElementClickInterceptedException' occurred in WebDriver.dll but was not handled in user code element click intercepted: Element <button data-v-7b27a432="" type="submit" class="btn btn-primary btn-sm form-control mt-3">...</button> is not clickable at point (464, 863). Other element would receive the click: <i data-v-5e808f53="" class="font-20 d-block mb-1 icon-question"></i>

This is Html Code Of Button :

<button data-v-7b27a432="" type="submit" class="btn btn-primary btn-sm form-control mt-3">Tiếp Tục</button> .

It ready find that elment but cant click or cant submit that button

undetected Selenium
  • 183,867
  • 41
  • 278
  • 352

2 Answers2

0

Please try below solution :

IWebElement element = driver.FindElement(By.Xpath("//button[contains(text(),'Tiếp Tục')]"));

Actions action = new Actions(Driver);
action.MoveToElement(element).Perform();
action.Click();   
SeleniumUser
  • 4,065
  • 2
  • 7
  • 30
0

The click on the element so you have to induce WebDriverWait for the desired ElementToBeClickable and you can use either of the following Locator Strategies as solutions:

  • Using CssSelector and Submit():

    new WebDriverWait(driver, TimeSpan.FromSeconds(20)).Until(ExpectedConditions.ElementToBeClickable(By.CssSelector("button.btn.btn-primary.btn-sm.form-control[type='submit']"))).Submit();
    
  • Using XPath and Click():

    new WebDriverWait(driver, TimeSpan.FromSeconds(20)).Until(ExpectedConditions.ElementToBeClickable(By.XPath("//button[contains(@class, 'form-control') and text()='Tiếp Tục']"))).Click();
    
undetected Selenium
  • 183,867
  • 41
  • 278
  • 352