Hi All,
From the main app window at the top, how would i navigate directly to the form object marked with red crosses.
Super-hero status and a blue peter badge to whoever cracks it
Thanks
navigating to a particular form object
Moderators: Dorian (MJT support), JRL
- Marcus Tettmar
- Site Admin
- Posts: 7395
- Joined: Thu Sep 19, 2002 3:00 pm
- Location: Dorset, UK
- Contact:
I would do it like this:
Press Tab
Repeat as necessary (or use the * n suffix).
Press Tab
Repeat as necessary (or use the * n suffix).
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar
Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar
Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?
I interpret your question as "How can I focus or work with this window, since it has no caption or window_title to work with?" Since just highlighting the entry in the "view system windows" utility would server no useful purpose I'm aware of.
Code: Select all
//Do something to make the desired window have the focus
//Use window handles since the title is blank
Let>WIN_USEHANDLE=1
GetActiveWindow>window_handle,X,Y
SetFocus>window_handle
Both, thanks for your replies
adroege, the item i wish to reach is a tree view list on a tabbed page on the form. rather than hop, skip and jump my way there I was hoping to be able to ascertain the 'handle' (?) of my treeview list and refer to it directly. So, whilst I can set the focus to the parent windown, my actual app, I then wanted to try and grab the treeview list within it.
If I were in Visual Studio I'd cycle through a list of controls on the form with a ForEach loop and (e.g) stop when I found one of type TreeView. Its that kind of approach I was investigating rather than emulating keystrokes. I will go the keystroke method if necessary but was, rightly or wrongly, looking at the problem through regular development eyes.
adroege, the item i wish to reach is a tree view list on a tabbed page on the form. rather than hop, skip and jump my way there I was hoping to be able to ascertain the 'handle' (?) of my treeview list and refer to it directly. So, whilst I can set the focus to the parent windown, my actual app, I then wanted to try and grab the treeview list within it.
If I were in Visual Studio I'd cycle through a list of controls on the form with a ForEach loop and (e.g) stop when I found one of type TreeView. Its that kind of approach I was investigating rather than emulating keystrokes. I will go the keystroke method if necessary but was, rightly or wrongly, looking at the problem through regular development eyes.
Have you tried.....
Code: Select all
GetTreeNode>WindowTitle,ClassName,Instance,Text,Case,Partial,Result,Handle
Returns in Result the index of the visible tree view node whose caption matches Text.