title: Check if userform open
body: <p>I run a program which repeats itself. It should stop, when the user closes the userform. It runs without stopping.</p>
  
  <p>Since the program calls itself every 8 seconds, I want to check at the end if the userform is still loaded / opened.</p>
  
  <pre><code>Public Sub NextPicture1()
     PictureChange = Now + TimeValue("00:00:08")
     If Onboarding_Projekt.Visible = True Then
        Application.OnTime PictureChange, "NextPicture1"
     End If
  End Sub
  </code></pre>