Tree Walker - missing control elements

I have a problem with the TreeWalker class. I use a .RawViewWalker TreeWalker for building up a tree of all elements. I made a simple application using Avalon: one Form with a button, a checkbox, an ink canvas and a menu on it. My problem is, that using the TreeWalker the elements ink canvas and the menu are not found, just the button and the checkbox. I cannot solve this problem.

I have another question about this whole namespace System.Windows.Automation: is it better than using the namespace Reflaction

Thanks in advance!


Answer this question

Tree Walker - missing control elements

  • Some Name

    Hello Mark one of the primary benefits of using Microsoft UIA for automated testing is that it allows a tester to write test automation against another process. This process may not be an application that the tester owns so UIA allows tests to interoperate. Also Microsoft UIA is a programmatic access standard, so rather than using reflection to test out application specific interfaces, one can use UIA to perform generic actions and obtain standardized access to information. One of the goals of Microsoft UIA is to make automated testers and assistive technologies more productive by spending time on their tests/accessibility products rather than figuring out how to obtain information. When an application provider implements the Microsoft UIA interfaces they make it easier for test automation and assistive technologies to work with their products out of the box.


    Thomas



  • ayu

    The Beta 2 CTP will be released very soon. Can you check that build to see if the issue still repros It is a known issue that the Ink Canvas was not available as part of Feb CTP. Have you examined the UI using UISpy to see if the Menu is showing up in a different part of the tree

    Also can you clarify your question about namespace Reflaction I'm not quite sure what you're getting at.

    Thanks,

    Thomas



  • Jubber

    Hi Thomas!

    I will check that build when it is released. I did not use UISpy, because I build the whole tree, so the Menu element must have been in the subtree of the the application main element. Is it not true

    Precisely the root menu element is found, but e.g. if I have two menu items File and About, in the File there is an Exit. The exit is not found (for a WPF application). For a win32 application one automation element menuStrip is found, but it does not have children.

    My question about Reflaction and Automation namespaces: I write a program for Automated UI testing of WPF softwares. I could write it using Reflaction namespace, but I read that System.Windows.Automtation was made for Accessiblity and testing. Still I don't know why it is better for that.

    One more question: when will be the beta 2 of windows sdk released

    Thanks, Mark



  • Tree Walker - missing control elements