title: How to Play a section of the WPFmediaElement
body: <p>I need to play a section of the Mediaelement for example from the second 0:45 to 0:55 sec</p>
  
  <p>I tried using the mediaelement  position property here is the code</p>
  
  <pre><code>            Dim mytimeline As New MediaTimeline
              Dim mc As MediaClock
  
              FReveal1.Visibility = Windows.Visibility.Visible
  
              FReveal1.Source = New Uri("videos\Front-Game-Answer-Reveals.wmv", UriKind.Relative)
  
              FReveal1.Position = New TimeSpan(0, 0, 4)
  
              mytimeline.Source = FReveal1.Source
              mytimeline.Duration = (TimeSpan.FromMilliseconds(5000))
              mc = myTimeLine.CreateClock()
              FReveal1.Clock = mc
              FReveal1.Play()
  </code></pre>
  
  <p>But I get the following error : "Cannot perform this operation while a clock is assigned to the media player."</p>
  
  <p>Is there another way to do this ?</p>
  
  <p>Thanks</p>