Stream Deck + AutoHotkey + PowerPoint = You’re Welcome

I am not a streamer… yet. I work on business plans and PowerPoint presentations all day. Maybe someone would watch me drag clipart around on Twitch?

But, I do own an Elgato Stream Deck. I am always discovering more ways to use it: home automation, muting the right audio source, and loading programs with a touch of a button. A Stream Deck is a grid of physical buttons that have a little display behind them. The buttons can do whatever you want whenever you press them. The displays can show you icons, animations, and statuses.

Elgato Stream Deck Mini

I have spent a fair amount of time learning how to customize my Stream Deck and incorporate it into my daily work.

Vicious Cycle

The one thing that I do every day is give PowerPoint presentations on Microsoft Teams. Frequently during a presentation, I am getting messages in the chat. When I click over into Teams to check on what the chatter is, I lose focus on PowerPoint. Then, I try to advance the slides. PowerPoint doesn’t move. I look stupid. I question my worth. I am spiraling. And then I realize! I click back on PowerPoint and save the day. Slides are now moving forward. Then, someone sends a message, I click on Teams to check out what I am saying wrong and try to advance the slides and nothing.

A Solution

I have found a solution. Admittedly, it’s complicated. If you use Windows, this solution might work for you too. I dedicate two buttons on the Stream Deck to move the slides forward and backward (for those times I have to go back a slide). This works because the Stream Deck can be customized to send a keyboard command to your PC, then AutoHotkey can map the command to a little script. The script brings PowerPoint into focus and sends a keyboard command to PowerPoint. So, no matter where you have clicked during a presentation, your slides move forward and backward and you don’t have to question your self-worth!

AutoHotkey

Install AutoHotkey on your Windows PC. AHK will run in the background waiting for keyboard commands that match the rules that you have created. For help, check out the documentation and the Hello World video on YouTube. I know, it will be daunting, but a community of people for the last decade have been creating videos, examples, and tutorials. You just have to stick with it for a while. You just might be inspired to automate other computing tasks. My goal is to map F13 and F14 (yes there are function keys beyond F12) to Page Up and Page Down. Page Up and Page Down are keyboard shortcuts for PowerPoint. I am using the nowhere to be found F13 and F14 keys so I don’t accidentally press those keys on my keyboard. I want the Stream Deck to have control over the PowerPoint slides.

  1. Right-click on your desktop
  2. Find “New” in the menu
  3. Click “AutoHotkey Script” inside the “New” menu
  4. Name it PowerPoint.ahk
  5. Right-click on PowerPoint.ahk and click “Edit Script”
  6. Enter and save the code below:

F13::
    if WinExist("PowerPoint Slide Show")
    {
        WinActivate ;
        Send {PgDn}
        return
    }

    return

F14::
    if WinExist("PowerPoint Slide Show")
    {
        WinActivate ;
        Send {PgUp}
        return
    }

    return

Stream Deck

On the Stream Deck app, drag over a “Hotkey” to one of your buttons. In the Hotkey field, click the down arrow, select F-Keys, and F13. Do this for F14 as well. For the icons, I just used icons found on Wikipedia pages.

Selecting the F13 F-Key in Stream Deck
My PowerPoint Config for Stream Deck

Demo Time

I have to say that this really makes giving a PowerPoint easier. I hope you find it useful. Let me know if you try it our modify this project to solve something else.

Update

I received a bunch of email after I posted my Stream Deck project to control PowerPoint. Some were happy to see the clues to make their AutoHotkey scripts work properly and others were wondering how to do this without a Stream Deck. Stream Deck controllers are really awesome and have been in high demand over the past year. I have a solution for you. I discovered a $10 PowerPoint presenter device by KNORVAY/NORWII where the buttons are programmable to control PowerPoint with AutoHotkey. Check out the full tutorial here.

Controlling PowerPoint with the KNORVAY N27 Presenter

2 comments

  1. Hi Mr Scharler,

    I’m extremely happy that I came across your AutoHotKey explanation for how to combine AutoHotKey, PPT and Streamdeck. Coincidentally I am setting up a streaming rig for my church and need to advance PPT slides while PPT is being used as a source in OBS Studio.

    My task is distilling a somewhat complicated 2 camera, BlackMagic switcher and audio mixer setup into a package that can be operated by a novice (with the help of a small child, perhaps) and advancing the PPT slides from within OBS caused me some lost sleep. I quickly realized that which program had focus would be a hurdle.

    I think the AHK routine should save my day.

    Thanks for pointing the way.
    Tom Ingledew

    1. Hi Tom,

      Thanks for the comment. I am glad this might help you out. Let me know how it goes and godspeed.

      Hans

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.