Can we find element by ID in appium

前端 未结 6 730
野的像风
野的像风 2020-12-09 04:13

following link mentions that we can find element by giving id... but i am unable to find it.

https://github.com/appium/appium/blob/master/docs/en/writing-running-app

6条回答
  •  北荒
    北荒 (楼主)
    2020-12-09 04:43

    In the Appium version 1.0 onwards, findElementByTagName is deprecated.

    You have to use the findElementByClassName instead with qualified class Name. Code for EditTextField and Button in android as below :

    findElements(By.className("android.widget.EditText"));

    findElements(By.className("android.widget.Button"));

提交回复
热议问题