Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. WCF and WF
  4. problem with Refreshing Binding Source in Media Element

problem with Refreshing Binding Source in Media Element

Scheduled Pinned Locked Moved WCF and WF
wpfwcfhelpquestion
3 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • F Offline
    F Offline
    Feras Mazen Taleb
    wrote on last edited by
    #1

    I'm using Media Element to Dispaly Video & pictures the binding to Source Property made with Convertor that Save the Binary Data to A file and return the URI of this file to the Media Element Every thing works well but When Edit The File and put other Movie or Picture the Displayed Picture Is Still the previous one until I close the Window and ReOpen it to get the Newest one this is the Binding Xaml :

    <MediaElement.Source >
    <MultiBinding Mode="TwoWay" Converter="{StaticResource RefConverter}" >
    <Binding Path="AddAnimationReference.File" Mode="TwoWay" />
    <Binding Path="AddAnimationReference.Extention" Mode="TwoWay" />
    <Binding Path="AddAnimationId" Mode="OneWay" />
    </MultiBinding>
    </MediaElement.Source>

    The convertor Code is so simple and I debugged it so I think there is no problem on this . thanks :)

    You have To Search About The Truth Of Your Life Why Are you Here In Life ?

    C 1 Reply Last reply
    0
    • F Feras Mazen Taleb

      I'm using Media Element to Dispaly Video & pictures the binding to Source Property made with Convertor that Save the Binary Data to A file and return the URI of this file to the Media Element Every thing works well but When Edit The File and put other Movie or Picture the Displayed Picture Is Still the previous one until I close the Window and ReOpen it to get the Newest one this is the Binding Xaml :

      <MediaElement.Source >
      <MultiBinding Mode="TwoWay" Converter="{StaticResource RefConverter}" >
      <Binding Path="AddAnimationReference.File" Mode="TwoWay" />
      <Binding Path="AddAnimationReference.Extention" Mode="TwoWay" />
      <Binding Path="AddAnimationId" Mode="OneWay" />
      </MultiBinding>
      </MediaElement.Source>

      The convertor Code is so simple and I debugged it so I think there is no problem on this . thanks :)

      You have To Search About The Truth Of Your Life Why Are you Here In Life ?

      C Offline
      C Offline
      Christian Graus
      wrote on last edited by
      #2

      I suspect the issue is simply that there's no file watcher telling the control to reload, so you need to do it yourself. FWIW, I've found the MediaElement doesn't show some pictures, so I use a dual control to use an Image control for stills, and the MediaElement for video.

      Christian Graus Driven to the arms of OSX by Vista. "! i don't exactly like or do programming and it only gives me a headache." - spotted in VB forums. I can do things with my brain that I can't even google. I can flex the front part of my brain instantly anytime I want. It can be exhausting and it even causes me vision problems for some reason. - CaptainSeeSharp

      F 1 Reply Last reply
      0
      • C Christian Graus

        I suspect the issue is simply that there's no file watcher telling the control to reload, so you need to do it yourself. FWIW, I've found the MediaElement doesn't show some pictures, so I use a dual control to use an Image control for stills, and the MediaElement for video.

        Christian Graus Driven to the arms of OSX by Vista. "! i don't exactly like or do programming and it only gives me a headache." - spotted in VB forums. I can do things with my brain that I can't even google. I can flex the front part of my brain instantly anytime I want. It can be exhausting and it even causes me vision problems for some reason. - CaptainSeeSharp

        F Offline
        F Offline
        Feras Mazen Taleb
        wrote on last edited by
        #3

        wow thanks ! It is a great idea I will use the file Watcher Component I think the same as windows forms one or maybe the same class

        You have To Search About The Truth Of Your Life Why Are you Here In Life ?

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups