I'm very newbie in Python and I'm trying to make login on Dell OpenManage webpage below by using Selenium:
I already tried too many ways to locate the xpath of the Username box (/html/body/div1/div[2]/div/div/div1/div[6]/form/table/tbody/tr[2]/td1/input), but without success.
In the latest test I tried to wait the element be loaded to use send_keys and I received the error message below:
Traceback (most recent call last): File "C:\LEARN\PY\RepositoryGitHub\Ancora-Automations\Ancora-Automations\ServersCheck.py", line 18, in wait.until(EC.presence_of_element_located((By.XPATH, "/html/body/div1/div[2]/div/div/div1/div[6]/form/table/tbody/tr[2]/td1/input"))).send_keys('ezequiel.ferreira') File "C:\Users\ezequiel.ferreira\AppData\Local\Programs\Python\Python39\lib\site-packages\selenium\webdriver\support\wait.py", line 90, in until raise TimeoutException(message, screen, stacktrace) selenium.common.exceptions.TimeoutException: Message:
My code is:
from selenium import webdriver
from webdriver_manager.chrome import ChromeDriverManager
from selenium.webdriver.chrome.service import Service
from selenium.webdriver.common.by import By
from selenium.webdriver.support.ui import WebDriverWait
from selenium.webdriver.support import expected_conditions as EC
import tkinter as tk
from tkinter import simpledialog
service = Service(ChromeDriverManager().install())
driver = webdriver.Chrome(service=service)
driver.get('https://ancorabk02:1311/OMSALogin?msgStatus=null')
wait = WebDriverWait(driver, 2)
# Clicking on advanced and continue buttons to proceed on a untrusted page
driver.find_element('xpath', '/html/body/div/div[2]/button[3]').click()
driver.find_element('xpath', '/html/body/div/div[3]/p[2]/a').click()
wait.until(EC.presence_of_element_located((By.XPATH, "/html/body/div[1]/div[2]/div/div/div[1]/div[6]/form/table/tbody/tr[2]/td[1]/input"))).send_keys('ezequiel.ferreira')
Could you please help me to understand with this issue?
Thanks!