GetChildWindowList

Technical support and scripting issues

Moderators: JRL, Dorian (MJT support)

Post Reply
User avatar
JRL
Automation Wizard
Posts: 3532
Joined: Mon Jan 10, 2005 6:22 pm
Location: Iowa

GetChildWindowList

Post by JRL » Mon Apr 12, 2010 5:36 pm

The GetWindowList> function will provide a list of open top level windows. I'd like to be able to get a list of all child windows from a specified top level window. Has anyone thought of a way to do this?

I have a number of scripts that automate processes for an ERP package. Every time we update I spend a couple of days fixing these scripts because the vendor has moved the locations of fields and buttons in the dialogs I'm attempting to autocomplete. I think if I could acquire the list of button and field names I could write the script to detect the locations of the appropriate buttons, check boxes, fields, etc. then use the detected locations rather than hard coded locations.

Anyone have any thoughts on this?


Thanks,
Dick

gdyvig
Automation Wizard
Posts: 447
Joined: Fri Jun 27, 2008 7:57 pm
Location: Seattle, WA

Post by gdyvig » Mon Apr 12, 2010 6:20 pm

Hi JRL,

FindWindowWithText uses the same routines as the View System Windows tool. If the window title or class of the child object remains the same you might be able to find it.

GetActiveWindow with GAW_TYPE will retrieve info about the active child window of the currently active top level window. You may be able to use that, as you navigate through the child windows they should become active in turn.


Gale

User avatar
JRL
Automation Wizard
Posts: 3532
Joined: Mon Jan 10, 2005 6:22 pm
Location: Iowa

Post by JRL » Mon Apr 12, 2010 6:25 pm

Thanks Gale, I'll give that a shot. I'll post whatever I come up with.

Post Reply
Sign up to our newsletter for free automation tips, tricks & discounts