You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
In CalculatorApp FlaUI doesn't get all descendents of CalculatorResults element, which are visible in Inspect.exe
Code snippets
using FlaUI.Core.AutomationElements;using FlaUI.UIA3;varautomation=new UIA3Automation();varapplication= automation.FromHandle(987676);// use CalculatorApp NativeWindowHandlevarwindow= application.AsWindow();vartext= window.FindAllDescendants().Where(d => d.Properties.AutomationId.IsSupported).SingleOrDefault(d => d.AutomationId =="CalculatorResults");varallDescendants=text!.FindAllDescendants();
Console.WriteLine($"{text.AutomationId} has {allDescendants.Length} descendants");
Console.ReadLine();
Screenshots
FlaUI
Inspect
Additional context
As you can see in Inspect screenshot inside CalculatorResultsText element there is another Pane which has another Text element. I've tried to dig inside FindAllDescendants method but it's basically a straightforward proxy to UI Automation FindAll. Trying also to access directly with its own AutomationId (NormalOutput) returns null.
The text was updated successfully, but these errors were encountered:
I have experienced a problem with FindAll too that it not always traverses the whole tree.
A workaround for me was to first get a direct child, then get the descendant of that child (so stepping through the tree one child after another).
I tried logging an issue via the Feedback Hub Microsoft app: https://aka.ms/AAnqw26. If there is any other way of raising this (e.g. is there a GitHub project for UI Automation 3?) then let me know!
Describe the bug
In
CalculatorApp
FlaUI doesn't get all descendents ofCalculatorResults
element, which are visible in Inspect.exeCode snippets
Screenshots
FlaUI
Inspect
Additional context
As you can see in Inspect screenshot inside
CalculatorResults
Text
element there is anotherPane
which has anotherText
element. I've tried to dig insideFindAllDescendants
method but it's basically a straightforward proxy to UI AutomationFindAll
. Trying also to access directly with its ownAutomationId
(NormalOutput
) returnsnull
.The text was updated successfully, but these errors were encountered: