Hi John:
Microsoft does allot of dynamic ReArranging of form contents in their
software.
I am not much of a scriptor but I think that if you can find the button the
first time you can save the name or other property to identify it then look
for it within whichever group appears to remain static.
There are also tools you can use to analyze the tree of controls to find the
id of the button you are interested in.
If the whole thing is dynamic you have no choice me thinks but to search
from the top or from whichever branch appears to remain static.
I'll have to leave it to the real scripters to put in the technicals but
from a Microsoft point of view things can dynamically change including some
handles of controls.
At least that was the case in vb.net and vwd which are 2 Microsoft products
I mucked with scripting some time ago.
Rick USA
----- Original Message -----
From: "Jonathan C. Cohn" <[email protected]>
To: <[email protected]>
Sent: Thursday, February 13, 2014 5:31 PM
Subject: MSAA finding a specific button to activate.
Good Evening,
I am trying to click a specific button in the Lync Attendee application from
Microsoft.
How can I search for a button with the name "Share" without investigating
the entire MSAA hierarchy?
The button is the forth child of the ModeBar which is the second item of
the window that immed Application tells me has focus
I was able to do something like:
ClientInformation.Overlap.Accessible.Children(1).Children(4).Children(2).Children(4).select(1)
This awkward sequence initially causes the button to gain focus, but
eventually another item in the MSAA tree moves the position or the ModeBar
is hidden, or a dialog is active.
Thanks for any suggestions you might have.