Code: Select all
mouseXY(0, 0)
If there is anyone who could help me out eith this i would greatly appreciate it
Kind regards,
Yasin
Code: Select all
mouseXY(0, 0)
Code: Select all
F10::MouseXY(0,SubStr(A_ThisHotkey,2))
Code: Select all
F1::
F2::
F3::
F4::
F5::
F6::
F7::
F8::
F9::
F10::
F11::
F12::
MouseXY(0, LTrim(A_ThisHotkey, "F")) ; calls MouseXY (pass as second parameter the name of the most recently executed hotkey "A_ThisHotkey" trimming "F" from the beginning of the string)
return
mouseXY(__x, __y) {
MsgBox % __x . "," . __y ; for example
}
Code: Select all
Loop % 12
{
f := Func("mouseXY").bind(0, a_index) ; creates a func object and binds it predefined parameters so that when the func object is called, it calls the function passing it automatically any bound parameters
Hotkey % "F" . a_index, % f ; set the hotkey using the hotkey command which allows us use variables and set the boundfunc object as label
}
return ; end of the auto-execute section
mouseXY(__x, __y) {
MsgBox % __x . "," . __y ; for example
}
; see also: https://www.autohotkey.com/docs/objects/Func.htm
; https://www.autohotkey.com/docs/commands/Hotkey.htm
Users browsing this forum: Google [Bot], Holarctic, ishida20, jameswrightesq, Lem2001 and 403 guests