U don't wanna use handle, Rishi, as those change w/each program run. U
may also need to check Control ID, because these, too, have started to
change w/each run of the program, especially if it's written in .net.
The general outline for such a script is to find the handle of the
window in question, often by using functions like
FindDescendantWindow(), FindWindow(), or similar--there are a lot of
ways to do this. Then u try a setFocus() command, which may or may not
work--you'll know it did if u end up in a different window. If not,
then your next option is to try a MoveToWindow() command. These
commands will use the handle of the window u found w/whatever function
u used to find the window.
Here's a really simplistic example using The FindDescendantWindow
command. The control id of the window in this example is assumed to be
1.
Script FindMyWindow()
; ctrl shift jaws key f
var
handle hw
let hw = findDescendantWindow(GetAppMainWindow(GetCurrentWindow(),1)
;finds window starting from the current window
if (hw) then ;handle was found
SetFocus(hw)
endif
EndScript
Let me know if the concepts at least were understandable.
On 8/20/15, Rishi D Mack <minimack_19@xxxxxxxxxxx> wrote:
Hey guys, I hope someone can help me. I want to be able to create a
keystroke to jump from one window using window ID or handle. can you help
me?
I've been trying to do this for a while.
let's say the main window is
0001
and there's two windows with several buttons.
there's
Window_A 0002
Window_B 0003
Window_C 0004
Window_C which is 0004 has two buttons.
play0005
and stop 0006
How can I move to different windows, and then, how can I activate those
buttons by using an activate object or something?
Hope someone's understanding what I'm trying to do.
Thanks, Rishi
__________�
View the list's information and change your settings at
//www.freelists.org/list/jawsscripts