Detect Video Stop or Restart Video After Completion

Is there a way to do one of the following: 1) detect when a video has stopped at the end of the video or 2) start it back at the start of the video when it’s complete?

It’s weird and cumbersome in the UX to have to use the scroll bar to scroll a video back to the start after it’s done playing.

I’ve tried using while and forever blocks with the “from Video get Play” block. The get Play block doesn’t seem to switch to false when it’s not playing or when it’s completed.

Start it back as in a loop, like a gif?

Not so much loop, but make it so that if you push play again it starts the video over. Right now you have to use the video time slider to slide it back to the start and then push play.

hmmm is the video the only thing on the page? Maybe if the video finishes you could set the app to travel again to that same screen and that might be a work around?

Or if the video starts when the page opens you could try a loop?

The only problem is I can’t tell when the video is going to end. There’s no way to detect it that I’ve figured out.

Is it the same video every time?

It would be cool to see a block snippet for

Get is video1 playing: true/false
1 Like

No, unfortunately, different videos. User recorded.

Yes it would be great to have that block. I second that!

Same issues/requests here. One more, kind of related. I can’t seem to get ‘set play’ to switch to false using any method recommended. Worse, if a video is playing and you navigate away from the screen before it ends, the sound keeps playing in the background until the end of the video.

+1, could really use this feature. I’m playing video messages between users, and it’s not a great experience for them to have to drag the scrubber all the way back to the beginning.

1 Like

Hey guys anyone got solution for this?
I think there should a on video completion block as they have it on MIT app inventor.

1 Like

To do this, make a While Loop:
While Video’s Play = True: Wait 1 Second

Below the loop, put whatever you want to happen after the video has finished playing (e.g. replay the video from the start, or start a new video, etc.)

Edit:
Note: if the user hits the pause button on the video, this will be detected by the app as the same thing as the video completing. This will probably be a problem for most.