Wednesday 18 September 2013

Selenium Webdriver Upload File sendkeys don't work

Selenium Webdriver Upload File sendkeys don't work

I need to automate upload file.
This does not work:
WebElement FilePath = driver.findElement(By.name(//name));
FilePath.sendKeys(//path);
This is the behavior is manual execution:
Step 1: Click Browse Button

Step 2: Select File from "Upload File" Box

Step 3: Click Open then you will see the file has been selected

Step 4: Click Validate Button


Please Help me.
Thanks.

No comments:

Post a Comment