MediaPlayer R3 2016

2 posts, 1 answers
  1. Michel
    Michel avatar
    44 posts
    Member since:
    Sep 2011

    Posted 27 Oct 2016 Link to this post

    Setting the Media in the player declaration for playing mp3 is quite easy :

    .Media(m => m
    .Title("this is my song")
    .Source("sounds/mysong.mp3")            )
    .HtmlAttributes(new { style = "height:360px; width:640px" } )

    But how to change the media source for example if I want to change "mysong.mp3" to "myothersong.mp3" in an event in javascript :

    function onChange(arg)




    Many thanks

  2. Answer
    Eyup avatar
    3323 posts

    Posted 01 Nov 2016 Link to this post

    Hi Michel,

    Yes, you can change the video source dynamically using the media method of the client-side object of the player widget. Please check the following section and the referenced live demo to see how you can achieve that:

    I hope this will prove helpful.

    Telerik by Progress
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Back to Top