Monday 24 April 2017

Locating an element to test with FlaUI

The WinForms application I'm trying to test is legacy in more ways than I'd like.

Here is FlaUI Inpect looking at a login form I want to test. I need access to 4 items. Each has an AutomationId. The ids are: textUser, textPINCode, buttonHalt, buttonLogin

These 4 controls are custom controls derived from Krypton controls. I think the Krypton controls derive from Windows Forms 2.0

Suppose I have a handle on the top level window ("FormSplashScreen"). What is the XPath to get one of the 4 I want (say textUser)?

3 comments:

  1. Using GetMainWindow seems to be very very unreliable (because Windows messes those up if there is a splash screen). Use app.GetAllTopLevelWindows(automation)[0] instead. Would be great if you could try that.

    ReplyDelete
  2. FlaUInspect is supposed to be a modern alternative, based on FlaUI.
    In the below video, I had explained about "Installation of Accessibility Tool - FlaUInspect".
    https://youtu.be/VYmxWXCGGB0

    ReplyDelete
  3. Also I explained about "Working with Accessibility Tool - FlaUInspect". in the below video:
    https://youtu.be/790e_YlV16A

    ReplyDelete