Forum Xamarin Test Cloud (Read Only)

Skipping a descendent in the view tree

The implementation of one of our controls (bindable picker) has changed a bit and now has the control's label ahead of the selected item's label in the view tree. When I call .Descendent() I'm told the sequence contains more than one element since there are two text views in the hierarchy. ]

I used to call:
App.Query(c => c.Marked(Automation.ProfilePageView.AccountType).Descendant("android.widget.TextView")).Single().Text
to access the selected item's value, but that doesn't seem to be an option anymore.

Does anyone know if there's a way to skip the first matching descendent, or maybe exclude a query result based on an identifier? I tried to daisy chain .Descendent() calls, but that doesn't seem to work either. In the image below I'm trying to access "female" but can't seem to get past "gender".

Best Answer

Answers

Sign In or Register to comment.