Send commands to inactive window

Get help with using AutoHotkey (v1.1 and older) and its commands and hotkeys
bjennydy
Posts: 1
Joined: 16 Oct 2021, 01:14

Send commands to inactive window

Post by bjennydy » 16 Oct 2021, 01:26

Hello,
I am completely new to AutoHotKey and scripting. I am trying to run a presentation clicker to progress slides in ProPresenter 7 whether the window is active or not. I am 100% clueless as to how to do this and any help would be greatly appreciated.

Thanks in advance.

User avatar
mikeyww
Posts: 26939
Joined: 09 Sep 2014, 18:38

Re: Send commands to inactive window

Post by mikeyww » 16 Oct 2021, 06:51

Welcome to AHK. I think I would start by writing a script that works when the window is active. See Send and Click. Those pages provide both descriptions and examples. WinActivate may also help. After you have it working, you can look at ControlSend and ControlClick. You will also want a plain-language description of how you would go about advancing the slides: what keyboard or mouse actions would be needed to do it.

An example for PowerPoint is below. Running Window Spy will show you the WinTitle.

Code: Select all

#IfWinExist ahk_class screenClass ahk_exe POWERPNT.EXE
F3::
If !WinActive()
 WinActivate
Send {Space}
Return
#IfWinExist

Post Reply

Return to “Ask for Help (v1)”