Search code examples
excelvbavideouserform

How to play local video file on loop on an excel userform?


How to play local video file on loop on an excel userform?


Solution

  • Use an ActiveX control called Microsoft Media Player which is found via the Toolbox and then Additional Controls. Then set the url in the ide.

    To get the video to loop requires some code thus

    Option Explicit
    
    
    Private Sub UserForm_Initialize()
        WindowsMediaPlayer1.settings.setMode "loop", True
    
    End Sub