How to write xpath if parent and childs having the same class name and store the elements in the list

Did it solve your problem?

I did this for iOS:
Original XPATH:
//XCUIElementTypeApplication[1]/XCUIElementTypeWindow[1]/XCUIElementTypeOther[1]/XCUIElementTypeOther[1]/XCUIElementTypeOther[1]/XCUIElementTypeOther[1]/XCUIElementTypeOther[1]/XCUIElementTypeTable[1]/XCUIElementTypeCell[1]

Relative XPATH:
//*/XCUIElementTypeCell[1]

1 Like

Hi I am trying to find the element, could any one please help me the best way to find the element

In the above image, could any one guide me to find xpath for the native apps