Upload files using selenium

0
0

How to upload files from local via window prompt using selenium webdriver?

I want to perform the following actions:

  1. click on ‘Browse’ option on the window
  2. from the window prompt go to the particular location in the local where the file is kept
  3. select the file and click on ‘Open’ to upload the file.
  • You must to post comments
0
0

Have you tried using input() on proper file input control?

WebElement fileInput = driver.findElement(By.id("some id"));
fileInput
.sendKeys("C:/path/to/file.extension");
  • You must to post comments
Showing 1 result
Your Answer
Post as a guest by filling out the fields below or if you already have an account.
Name*
E-mail*
Website