Sign in to follow this  
Followers 0

UIAWrappers::_UIA_getObjectByFindAll partial title match

5 posts in this topic

#1 ·  Posted

I am parsing the rows of a tree control, but the parent window's title is variable along the lines of

Local $oP4=_UIA_getObjectByFindAll($oP5, "Title:=List: Items (1);controltype:=UIA_PaneControlTypeId;", $treescope_children)

the (1) may be anything, I was hoping I could partial match with "Title:=List: Items" but this does not work

Is there a way to get an object based on a partial title match?

Thank you

Share this post

Link to post
Share on other sites

#2 ·  Posted

a note that there are multiple items that match all the other criteria, maybe I can loop through looking for a title = List: Items (

Share this post

Link to post
Share on other sites

#4 ·  Posted (edited)

This is getting me closer and I will continue to investigate, at this point the wrong object is getting selected
The selection I am using is Title:=Orders: Path/Lab (.*)
The object getting selected has a title of "Deferred Orders: Path/Lab (0)"
The object I am looking for has a title of "Orders: Path/Lab(1)" in this case, but 1 could be any number

If I try this regedit, nothing is found

"Title:=/^Orders: Path/Lab&/ (.*;

Thank you for your help

Edited by HudsonKane
more information

Share this post

Link to post
Share on other sites

#5 ·  Posted

Well, if I use a correct expression, it works!

"Title:=^Orders: Path/Lab (.*);

Thank you for all the help you give in these forums, I have found many solutions from your responses to other questions

Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  
Followers 0

  • Similar Content

    • careca
      By careca
      Hey there, i have the code from simplespy but have no idea about what to use, got the UIA_V0_64 files.
      I look at the examples but i get lost, i ask for guideance in this matter.
      Best regards.

      To get to this window simply run:
      control.exe /name Microsoft.DefaultPrograms /page pageFileAssoc
      select a filetype and click "change program"
    • X_xkijux_x
      By X_xkijux_x
      Ok so im using this program. clarify for school. I would like to have a program that takes every word i type in microsoft word and searches on it in claryfi. is this possible. I would like to have the program not stopping me from typing more after that word. Like when i type a word it auto search it on clarify without making me stop typing and if i want to change i can do that and if im fine that word i can just keep typing and it will search after the next word. 
    • Miliardsto
      By Miliardsto
      Is this possible to make program works like in diagram? There is so much encryption methods and UDFs are they give security? If the $Address will be crypted with some encryption algorithm could be possible to get the value of $Address in easy way? Of course We know its easy too look into autoit code and get value of variable and so We dont want to anyone see $Address value - there are functions Could func1.au3, func2.au3.. be for example func1.php or other type of file? As we know .php files are unnable to see. For example func1 would be read by FileRead() and then Execute() Is this generally possible to do?
      Will it give secure?
      What do you think about? Maybe there is something wrong in this concept or missed.

    • zenocon
      By zenocon
      I'm building a fake WinForms GUI that I'm using to test.  In one instance, it has a panel with a number of text elements.  I have the inspect.exe output of the real target UI that I'm trying to automate, but I'm trying to build a fake one now that emulates it so I can more easily test.
      The problem is the order of the text elements in the pane is different, and I'm having a helluva time trying to figure out how to set the order -- if that's even possible.  The WinForms TabIndex property doesn't do it.  There is no Index property on it otherwise.  I'm worried it may not even be possible, so I figured I'd ask here.
      Thank in advance
    • zenocon
      By zenocon
      Consider the following image.  I'm interested in all of the text elements embedded in the last pane called "Power Container".  Unfortunately, this pane is embedded in 8 other panes with the same name and no other identifying characteristics.  I think I can get to the target pane using indexrelative.
      Local $powerContainer = _UIA_getObjectByFindAll($cPowerMain, "controltype:=UIA_PaneControlTypeId;Name:=Power Container;indexrelative:=8", $treescope_subtree) If Not IsObj($powerContainer) Then Return ConsoleWrite("Could not find Power Container pane") So, now I have the pane, but I want to target individual text elements.  They do seemingly have AutomationIds so I think I can use that as a selector.  Problem is I'm building a fake WinForms GUI to test with since I don't have access to the real UI to automate for testing purposes, and with WinForms, there is no way to set the AutomationId.  There is no other identifying information on these text elements.  Their Name property contains the actual data, which varies.  Except for the labels that sit in from of them.
      The way it is built it looks like this:
      My question is this: I know I can select to get the one with the static label value "Tag#"
      Local $tagLabel = _UIA_getObjectByFindAll($powerContainer, "controltype:='UIA_TextControlTypeId;Name:=Tag#", $treescope_subtree) Now, what I want to do is navigate to get the next sibling of this element.  It doesn't look like the API allows me to do this?  I think what I have to do is get a RawViewWalker and just iterate through all of them and inspect each one and figure out if it is what I'm looking for.   Does this seem correct?
      Is there a better way to achieve this?