Problems with buffering upon stopping/playing videos
Steps to reproduce 1. Put player on local video A and B 2. Assign script on both players to _stop_ each other on 'play' event 3. Click with mouse on one player and then on another Error ==> After several playing stopping second video stucks at buffering
Please send us a test page replicating the issue as described in the document below:
https://support.jwplayer.com/customer/portal/articles/2186238-troubleshooting-%E2%80%94-creating-a-test-page
We are not familiar with MS Visual Studio, so we will not be able to help out with troubleshooting that code, but I have created a code example using Javascript. I am using MP4 videos here. What kind of videos are you using?
Here is my code example to automatically pause all other videos but play the video the user has clicked on:
<div id="videoA"></div><br><br>
<div id="videoB"></div><br><br>
<div id="videoC"></div><br><br>
<div id="log"></div>
<script>
jwplayer('videoA').setup({
file: 'bunny.mp4'
}).on('play',function(){
pauseOthers(this.getContainer().id);
}); jwplayer('videoB').setup({
file: 'tears.mp4'
}).on('play',function(){
pauseOthers(this.getContainer().id);
}); jwplayer('videoC').setup({
file: 'sintel.mp4'
}).on('play',function(){
pauseOthers(this.getContainer().id);
}); function pauseOthers(id) {
console.log('Playback just started for: '+id);
var videos = document.getElementsByTagName('video');
for (i=0;i<videos.length;i++) {
if (id != videos[i].parentNode.parentNode.id) {
jwplayer(videos[i].parentNode.parentNode.id).pause(true);
console.log('Pausing: '+videos[i].parentNode.parentNode.id);
}
}
}
</script>