How to click in an edit box Topic is solved

Get help with using AutoHotkey (v1.1 and older) and its commands and hotkeys
ALYB
Posts: 7
Joined: 23 Feb 2018, 13:55

How to click in an edit box

23 Feb 2018, 14:08

How can I write a macro that clicks (places the caret) in the English edit box?

Image

Image
User avatar
Xtra
Posts: 2750
Joined: 02 Oct 2015, 12:15

Re: How to click in an edit box

23 Feb 2018, 15:24

NotePad Example:

Code: Select all

ControlFocus, Edit1, Untitled - Notepad
HTH
ALYB
Posts: 7
Joined: 23 Feb 2018, 13:55

Re: How to click in an edit box

24 Feb 2018, 04:25

Thank you! I'm running this macro from TextPad and I can see that the text cursor is placed in the correct edit box. However, after that, the right mouse button click and the other commands are send to TextPad again.

How can I have them send to my Resource Editor?

Code: Select all

#NoEnv  ; Recommended for performance and compatibility with future AutoHotkey releases.
; #Warn  ; Enable warnings to assist with detecting common errors.
SendMode Input  ; Recommended for new scripts due to its superior speed and reliability.
SetWorkingDir %A_ScriptDir%  ; Ensures a consistent starting directory.
^g::
ControlFocus, Edit4, Amax Resource Translator
sleep, 250
Click, Right
sleep, 250
sendinput {down}
sleep, 50
sendinput {down}
sleep, 50
sendinput {down}
sleep, 50
sendinput {down}
sleep, 50
sendinput {down}
sleep, 50
sendinput {down}
sleep, 50
sendinput {enter}
Click, Right
sleep, 250
sendinput {down}
sleep, 50
sendinput {down}
sleep, 50
sendinput {down}
sleep, 50
sendinput {enter}

User avatar
NovaRanger
Posts: 68
Joined: 23 Oct 2014, 02:05

Re: How to click in an edit box  Topic is solved

24 Feb 2018, 04:42

Hi,
replace

Code: Select all

sendinput {enter}
and

Code: Select all

Sendinput {down}

with

Code: Select all

 controlsend, Edit4, {enter}, Amax Resource Translator
and

Code: Select all

controlsend, Edit4, {Down}, Amax Resource Translator

Return to “Ask for Help (v1)”

Who is online

Users browsing this forum: Lamron750 and 256 guests