none
HTML Video Not Working With Visual Studio

    Question

  • Hi,

    I'm very new to visual studio and just started using about two months ago. I am currently building a website that I am trying to add video to, but for whatever reason the video only partly works. For example, half of the time, you can press play on the video and it will continue to play, but if you try to scrub through the video, it stops and then reloads when you try to press play again.

    The video plays fine from an html page made using a text editor, so it seems the problem lies with Visual Studio.

    I really have no idea what the problem could be, so any insight would be greatly appreciated. 

    Thursday, December 22, 2016 2:11 AM

All replies

  • Hi jstothfang,

    >>The video plays fine from an html page made using a text editor, so it seems the problem lies with Visual Studio.

    I think this may be related to your code and video, we could even use Notepad to develop Html project. So VS just let us develop web site conveniently. You could copy the code to the Notepad the run it in browse to see the results.

    I suggest you could use different MP4 video or OGG video to test the <video> tag again. In my side, I could play a MP4 video in my Html5 project. Here is my test code:

        <video width="320" height="240" controls="controls">
            <source src="movie.mp4" type="video/mp4" />
            <source src="movie.ogg" type="video/ogg" />
            <source src="movie.webm" type="video/webm" />
        </video>

    Sincerely,

    Oscar


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.


    Friday, December 23, 2016 9:03 AM
    Moderator