Forum Discussion

naveens33_'s avatar
naveens33_
Contributor
3 years ago

Desktop: Want to find a element in the hierarchy through the Sibling

In the below image, I want to find the highlighted element via its sibling WPFObject("TextBlock","FirstName",1). Any hope?  
  • naveens33_'s avatar
    naveens33_
    3 years ago

    Currently I did a workaround for this

     

    find_following_sibling_element = lambda child1,element_name,depth=0 : child1.Parent.FindChild('Name',element_name,depth)