locked
I need a tutorial to make a media 'seeker', preferably without writing too much code. RRS feed

  • Question

  • I've already tried searching both the web and the forums. I can't find any...
    Sunday, January 31, 2010 2:22 PM

All replies

  • Border b = (Border)sender;
    Point p = e.GetPosition(b);
    Double pourcentPosition = p.X / b.ActualWidth * 100;
    
    if (pourcentPosition >= DownloadProgressBar.Value * 100)
    {
        pourcentPosition = DownloadProgressBar.Value * 100;
    }
    
    Media.Position = TimeSpan.FromSeconds(Media.NaturalDuration.TimeSpan.TotalSeconds / 100 * pourcentPosition);
    • Proposed as answer by ssk123 Monday, February 1, 2010 4:47 AM
    Sunday, January 31, 2010 10:20 PM
  • Umm more detail please? Where should I paste it? How does the code know what media element to use? How does it know which slider to use? Sorry, I'm not all that good with code...
    Monday, February 1, 2010 11:49 AM