Using other automation tools for Windows Apps, such as LeanFT, there is a way to specify a visual relation. For example, if I identified a label, I could then say look for the text box to the right of it.
Is there a way to do this in Winium?
Here is a sample of what the code looks like in LeanFT
var projectButton = baseOR.PlatformWindow.ProjectList.BrowseProjects.Describe<IButton>(new ButtonDescription
{
FullType = "button",
Text = node,
Index = 0
});
return baseOR.PlatformWindow.ProjectList.BrowseProjects.Describe<IButton>(new ButtonDescription
{
FullType = "button",
Vri =
{
new VisualRelation
{
TestObject = projectButton,
HorizontalRelation = HorizontalVisualRelation.LeftAndInline,
}
}
});
As you can see, we are essentially identifying one element, and then using that as the TestObject in the VisualRelation to identify something else.