Resource icon

Non-OBS Script PowerPoint macro for controlling OBS

I wrote a quick VBA macro that will send keystrokes to OBS tot ell it to change scenes. This way your OBS scenes can change when you move through PowerPoint slides. Means I never have to touch OBS when I’m presenting PowerPoint. Saves me a tonne of work and is kind of simple and awesome.

This is it in action.

Here’s the macro script

Sub OnSlideShowPageChange()
Dim i As Integer
Dim sNotes As String
Dim sKey As String

i = ActivePresentation.SlideShowWindow.View.CurrentShowPosition
s = Left(ActivePresentation.Slides(i).NotesPage.Shapes.Placeholders(2).TextFrame.TextRange.Text, 4)

If Left(s, 3) = "OBS" Then
sKey = "^" & Right(s, 1)
AppActivate ("OBS")
SendKeys (sKey), 1
AppActivate ("PowerPoint")
End If
End Sub

a few notes...
1. Set up shortcut keys in obs CTRL+1 for your first scene, CTRL+2 for your second etc
2. In PowerPoint, add the above script to your macros
3. In your notes field for each slide make sure the first thing in that field is OBS1 or,OBS2 etc. The script will read the first 4 characters in your it’s field when you move to that slide and if it sees OBS1 it will send CTRL+1 to OBS etc.

Pretty simple.

Hope someone else finds this useful, it has simplified my workflow dramatically.
First release
Last update
5.00 star(s) 1 ratings

Latest reviews

I had to make 1 tiny change in the script & enable the Macros to make it work on my PowerPoint 365. Works like a charm.