How to select a Class NN control Topic is solved

Get help with using AutoHotkey (v1.1 and older) and its commands and hotkeys
OCP
Posts: 98
Joined: 28 Mar 2018, 19:28

How to select a Class NN control

20 Jun 2018, 04:21

hello folks

i am trying to eliminate the need for mouse clicks on positions so my script could work elsewhere without the need of editing coordinates, what i need is to access a class nn control, i want to move away from using mouse click completely where ever i can but i lack the knowledge to do it, i started using ahk about 7 months ago

right now i can get what i want by using a mouse click but that is unreliable in some cased
(see the commented out part in the vid to see how i do it now)

the class nn i need to access
ClassNN: TQuickEdit1
Text:
Color: 2F383D (Red=2F Green=38 Blue=3D)

i figured it would be easy-er to just show it in a small video

https://youtu.be/8jrATkDFEMU

i appreciated any help or pointer thank you
User avatar
Hellbent
Posts: 2109
Joined: 23 Sep 2017, 13:34

Re: How to select a Class NN control  Topic is solved

20 Jun 2018, 07:26

Have you tried controlClick?
It has always been a hit or miss command for me and acts differently with different windows, but it might work for you.

Seeing that your end goal is to send text to the control, you can omit clicking on it and just try going for ControlSend.

Code: Select all

;https://autohotkey.com/docs/commands/ControlClick.htm
;ControlClick , Control-or-Pos, WinTitle, WinText, WhichButton, ClickCount, Options, ExcludeTitle, ExcludeText

ControlClick ,TQuickEdit1, Remote control settings


;https://autohotkey.com/docs/commands/ControlSend.htm
;ControlSend , Control, Keys, WinTitle, WinText, ExcludeTitle, ExcludeText
;ControlSendRaw: Same parameters as above.
wolf_II
Posts: 2688
Joined: 08 Feb 2015, 20:55

Re: How to select a Class NN control

20 Jun 2018, 07:30

maybe try with ControlSetText
User avatar
jeeswg
Posts: 6902
Joined: 19 Dec 2016, 01:58
Location: UK

Re: How to select a Class NN control

20 Jun 2018, 07:32

Possibly it would help to do ControlFocus prior to Click/MouseClick/ControlClick.
homepage | tutorials | wish list | fun threads | donate
WARNING: copy your posts/messages before hitting Submit as you may lose them due to CAPTCHA
AHKStudent
Posts: 1472
Joined: 05 May 2018, 12:23

Re: How to select a Class NN control

20 Jun 2018, 07:34

Try

ControlSend, TQuickEdit1, 12345, Remote control settings
OCP
Posts: 98
Joined: 28 Mar 2018, 19:28

Re: How to select a Class NN control

20 Jun 2018, 07:39

solved it first post by hellbent already did the trick was playing around with controlfocus before that with no success

i will keep that piece of code you posted ahkstudent think ill need that elsewhere thnx

thnx all for the fast responses

Return to “Ask for Help (v1)”

Who is online

Users browsing this forum: aitaixy, Anput, dangoscrub, doodles333, joedf, Nerafius and 108 guests