Controlclick in Java based program

Get help with using AutoHotkey (v1.1 and older) and its commands and hotkeys
zckl9497
Posts: 2
Joined: 25 Oct 2018, 12:20

Controlclick in Java based program

25 Oct 2018, 12:57

So I need to automate some clicks in a Java based program. I don't really see much info on the spy so I installed Java bridge and tried the ferret but still can't manage to make it work

https://gyazo.com/bb2d476806c02c2033f91d0c87821cab

Here on the screenshot I'm holding the mouse over the "Fold" button. Let's say you wanted to click on it, what function would you write?
User avatar
Nextron
Posts: 1391
Joined: 01 Oct 2013, 08:23
Location: Netherlands OS: Win10 AHK: Unicode x32

Re: Controlclick in Java based program

26 Oct 2018, 08:18

That button is always in the same location within the window? If so, use coordinates instead of a name.
zckl9497
Posts: 2
Joined: 25 Oct 2018, 12:20

Re: Controlclick in Java based program

27 Oct 2018, 17:13

relative coordinates with controlclick doesn't work for some reason
Elgin
Posts: 124
Joined: 30 Sep 2013, 09:19

Re: Controlclick in Java based program

28 Oct 2018, 02:37

Hi!

See here on how to use the Java access bridge with AHK:
https://github.com/Elgin1/Java-Access-Bridge-for-AHK

There are several other threads on this forum, too.
Bensley
Posts: 6
Joined: 18 Nov 2017, 06:18

Re: Controlclick in Java based program

28 Oct 2018, 06:10

Can Java Access Bridge for AHK be used so controlclick can do a simple click on relative coordinates?
Elgin
Posts: 124
Joined: 30 Sep 2013, 09:19

Re: Controlclick in Java based program

28 Oct 2018, 07:41

You can use it to get the screen coordinates of a Java control an then do a mouse click there, if that's what you're looling for.
Bensley
Posts: 6
Joined: 18 Nov 2017, 06:18

Re: Controlclick in Java based program

28 Oct 2018, 07:52

Well i need something to be clicked without moving the mouse.
Elgin
Posts: 124
Joined: 30 Sep 2013, 09:19

Re: Controlclick in Java based program

28 Oct 2018, 08:37

That would be doing the click action or the focus action of a control, depending on the type of the control. No relative (or other) coordinates involved, though...

Return to “Ask for Help (v1)”

Who is online

Users browsing this forum: Sniperman and 388 guests