Have the below as part of my script:
^Up::WinMaximize, A ; Assign a hotkey to maximize the active window.
*This works...but doesnt work as part of the below script
F1::
Send !{y} ; Simulates the keypress alt+y
Sleep, 1000 ;wait 1 second
Send {ctrl down}Up{ctrl up}; sends the script to maximiz active window
Sleep, 1000 ;wait 1 second
Send {F4}
return ; Finished
For some reason doesnt maximise active window?...any help much appreciated
Many Thanks
Send script
Re: Send script
shimanov posted a good solution to this
https://autohotkey.com/board/topic/5444 ... er-hotkey/
use gosub
https://autohotkey.com/board/topic/5444 ... er-hotkey/
use gosub
Code: Select all
!z::
MsgBox, z
return
F10::
Gosub, !z
return
Re: Send script
Sorry mshall thats why over my head!
How do I send alt q & p press together.
So if I press the End button its sends the key press of alt, q & p- which is a shortcut already built into the software I'll be using?
Any help much appreciated.
How do I send alt q & p press together.
So if I press the End button its sends the key press of alt, q & p- which is a shortcut already built into the software I'll be using?
Any help much appreciated.
Re: Send script
End::
Send !{Q & P}
Return
Send !{Q & P}
Return
Re: Send script
Try
Send, {LAlt Down}qp{LAlt Up}
Send, {LAlt Down}qp{LAlt Up}
Re: Send script
And for your maximize problem try to use the handle of your window:
WinID:=WinExist("NameOfYourWindowPlaceHere")
WinMaximize, ahk_id %WinID%
WinID:=WinExist("NameOfYourWindowPlaceHere")
WinMaximize, ahk_id %WinID%
Re: Send script
Cheers frosti much appreciated! Tried the alt q p works perfect, not tried other yet
Re: Send script
Hi Frosti, cant get the other one to work after the send alt y bit?
F1::
Send !{y} ; Simulates the keypress alt+y
Sleep, 1500 ;wait 1 second
WinID:=WinExist(Activity)
WinMaximize, ahk_id %WinID%
Sleep, 1000 ;wait 1 second
Send {F4}
return ; Finished
Dont know if ive put the correct '"NameOfYourWindowPlaceHere"
On my Active Window Spy...Window Title, Class and process
Activity
ahk_class#32770
ahk_exe SBDDesktop.exe
Any help much appreciated, thanks in advance
F1::
Send !{y} ; Simulates the keypress alt+y
Sleep, 1500 ;wait 1 second
WinID:=WinExist(Activity)
WinMaximize, ahk_id %WinID%
Sleep, 1000 ;wait 1 second
Send {F4}
return ; Finished
Dont know if ive put the correct '"NameOfYourWindowPlaceHere"
On my Active Window Spy...Window Title, Class and process
Activity
ahk_class#32770
ahk_exe SBDDesktop.exe
Any help much appreciated, thanks in advance
Re: Send script
Hi,
The below will maximise the acive window but wont send F4>
F1::
Send, !{y} ; Simulates the keypress alt+y
Sleep, 1500
WinMaximize, A
Sleep, 3000
Send, {F4}
Return ; Finished
Thanks
The below will maximise the acive window but wont send F4>
F1::
Send, !{y} ; Simulates the keypress alt+y
Sleep, 1500
WinMaximize, A
Sleep, 3000
Send, {F4}
Return ; Finished
Thanks
Re: Send script
Try this instead:gazmoz17 wrote:F1::
Send !{y} ; Simulates the keypress alt+y
Sleep, 1500 ;wait 1 second
WinID:=WinExist(Activity)
WinMaximize, ahk_id %WinID%
Sleep, 1000 ;wait 1 second
Send {F4}
return ; Finished
Code: Select all
WinID:=WinExist("Activity")
Re: Send script
Hi, that all works great thanks and ive read some articles and reverse engineered a few things but...
Program Im in has existing shortcut alt f x (to close a the software program) I dont want to assign a single key to replicate this as theres too many to remember and im familiar with existing shortcut sequence.
But dont know how to write beginning of the script, I get errors at first line (alt f x)
!fx:
Send, {LAlt Down}n{LAlt Up}
Return
The alt n press closes a window pop ub box which asks you to confirm if the program wants to be backed up. n being no
Thanks in advance
Program Im in has existing shortcut alt f x (to close a the software program) I dont want to assign a single key to replicate this as theres too many to remember and im familiar with existing shortcut sequence.
But dont know how to write beginning of the script, I get errors at first line (alt f x)
!fx:
Send, {LAlt Down}n{LAlt Up}
Return
The alt n press closes a window pop ub box which asks you to confirm if the program wants to be backed up. n being no
Thanks in advance
Re: Send script
Similarilyexisting program short cut alt 01
I want to pres alt 01 and then get that to send tab 3 times?
Many Thanks
I want to pres alt 01 and then get that to send tab 3 times?
Many Thanks
Re: Send script
!01::
Send, {tab}
Sleep 250
Send, {tab}
Sleep 250
Send, {tab}
Return
Same error first line??
Thanks
Send, {tab}
Sleep 250
Send, {tab}
Sleep 250
Send, {tab}
Return
Same error first line??
Thanks
Who is online
Users browsing this forum: OrangeCat and 162 guests