I have a windows form with a aXWindowsMediaPlayer
which should play a random video/picture every 5 seconds using the method aXWindowsMediaPlayer.Url = <video/image file location>
.
This works fine for pictures, but when a video is longer it'll only play the 5 seconds and not the full length, same for a shorter video, it'll play the full video and leaving the other seconds with a black screen.
Is there a way to configure the mediaPlayer to only go to the next picture/video when it has played the videos full length?
EDIT1:
Something like:
Timer_TickEvent()//Every 5 seconds it chooses a random given URL
{
axWindowsMediaPlayer1.URL = <Random URL>;
if(<Random URL> == 'A video?')
{
timer.Enabled = false;
PlayVideoLength();
}
}
Private void PlayVideoLength()
{
if('<Random URL.Length> ?' == 'the length of the played video in axWindowsMediaPlayer1 ?')
{
Timer.enabled = true;
}
}
This code obviously wont work. It's an idea of what I want it to do.