How to locate the mouse position in edit window?

Get help with using AutoHotkey (v1.1 and older) and its commands and hotkeys
yerjoy
Posts: 8
Joined: 20 Dec 2021, 20:08

How to locate the mouse position in edit window?

Post by yerjoy » 24 Jan 2023, 21:09

Hello friends:
I want to make a find words function in an editwindow. After I input the words ddd and press find button the mouse will Located on the left side of bbbeeeeeeeeee. How to write the button code?
thanks a lot

Code: Select all

#SingleInstance force
fileencoding,UTF-8
SetBatchLines -1
#NoEnv

txtstr=aaaaaaa  bbbeeeeeeeeee`ncccccccc  ddd`neeeee`n

Gui, Add, Edit, vMyEdit   r10 ,%txtstr%

gui,Add,Edit,veefindstr x1 y180 w80,
gui,Add,button,gokbtn x100 y180,Find

Gui, Show,w200 h220
Return
Okbtn:

return

GuiClose:
ExitApp

[Mod edit: Removed excessive space between text and code. Added [code][/code] tags. Please use them yourself when posting code.]
Attachments
QQ截图20230125100835.jpg
QQ截图20230125100835.jpg (10.98 KiB) Viewed 169 times

Return to “Ask for Help (v1)”