TestProject Forum
Powered by leading experts in the test automation community

Issue with File upload

Hi, While trying to upload a file, I keep getting below error:

Message

org.openqa.selenium.NoSuchElementException: no such element: Unable to locate element: {“method”:“css selector”,“selector”:"#Browse upload2"}
(Session info: chrome=85.0.4183.83)
For documentation on this error, please visit: http://seleniumhq.org/exceptions/no_such_element.html
Build info: version: ‘3.4.0’, revision: ‘unknown’, time: ‘unknown’
System info: host: ‘DESKTOP-K7CFTCO’, ip: ‘127.0.0.1’, os.name: ‘Windows 10’, os.arch: ‘amd64’, os.version: ‘10.0’, java.version: ‘13.0.1’
Driver info: io.testproject.java.sdk.v2.drivers.WebDriver
Capabilities [{javascriptEnabled=true, platform=ANY}]
Session ID: 4def89f38cefd1d50f957fd5d3e93c8e
*** Element info: {Using=css selector, value=#Browse upload2} at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)

Element

Browse upload2

Searched by CSSSELECTOR:#Browse upload2

Need help to handle this.

Hey @venkatakrish, thanks for reaching out.
Seems like element’s locator value is incorrect,
Did you capture this element using TestProject Recorder?
if so, can you show me the step details?

we can troubleshot this issue using TestProject platform chat as well, which you can find by clicking this icon:
image