# Not able to identify element in andorid:widgetbutton in ViewGroup from different layout i.e Frame, Linear and Relative layout and it's not working

**URL:** <https://discuss.appium.io/t/not-able-to-identify-element-in-andorid-widgetbutton-in-viewgroup-from-different-layout-i-e-frame-linear-and-relative-layout-and-its-not-working/26651>\
**Category:** Support\
**Created:** [June 3, 2019, 1:45pm UTC](https://discuss.appium.io/t/not-able-to-identify-element-in-andorid-widgetbutton-in-viewgroup-from-different-layout-i-e-frame-linear-and-relative-layout-and-its-not-working/26651 "2019-06-03T13:45:21Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![usshah](https://discuss.appium.io/user_avatar/discuss.appium.io/usshah/32/5860_2.png) [@usshah](https://discuss.appium.io/u/usshah)\
**Post date:** [June 3, 2019, 1:45pm UTC](https://discuss.appium.io/t/not-able-to-identify-element-in-andorid-widgetbutton-in-viewgroup-from-different-layout-i-e-frame-linear-and-relative-layout-and-its-not-working/26651/1 "2019-06-03T13:45:21Z")

</div>

![Skip_button1](https://discuss.appium.io/uploads/default/original/2X/5/5759aa0fc87d5f9317cc86384ddf5c165a1bbb42.png)

\<android.widget.FrameLayout\>  
\<android.widget.LinearLayout\>  
\<android.widget.FrameLayout\>  
\<android.widget.FrameLayout\>  
\<android.widget.RelativeLayout\>  
\<android.view.ViewGroup\>  
\<android.view.ViewGroup\>  
\<android.view.ViewGroup\>  
\<android.view.ViewGroup\>  
\<android.view.ViewGroup\>  
\<android.view.ViewGroup\>  
\<android.widget.RelativeLayout\>  
\<android.view.ViewGroup\>  
\<android.widget.Button\>

|Attribute | Value|  
elementId : 6  
index : 0  
text :SKIP  
class :android.widget.Button  
checkable:false  
checked :false  
clickable :true  
enabled :true  
focusable : true  
focused : false  
scrollable :false  
long-clickable : false  
password :false  
selected : false  
bounds : [524,1308][700,1362]  
resource-id :  
instance : 0

I have tried different Xpath and name i.e…  
driver.findElement(By.xpath("/hierarchy/android.widget.FrameLayout/android.widget.LinearLayout/android.widget.FrameLayout/android.widget.FrameLayout/android.widget.FrameLayout/android.widget.RelativeLayout/android.view.ViewGroup/android.view.ViewGroup/android.view.ViewGroup/android.view.ViewGroup/android.view.ViewGroup/android.view.ViewGroup[2]/android.widget.Button")).click();

driver.findElement(By.xpath("[//android.widget.Button](https://android.widget.Button)[@text=‘SKIP’]")).click();

driver.findElement(By.name(“SKIP”)).click();

WebElement abc = driver.findElement(By.xpath("/android.widget.Button[@bounds=’[524,1308][700,1362]’]"))

No one Xpath and name is working…
