Occurs when a timeline marker is encountered during media playback.
Assembly: System.Windows (in System.Windows.dll)
XMLNS for XAML: Not mapped to an xmlns.
The event is not raised when the MediaElement seeks past a timeline marker. This event is raised whenever a marker associated with the media is reached. The marker might come from one of three locations:
Stored in the metadata of the currently opened media.
Associated with the currently opened media and coming from a separate stream.
Explicitly added to the Markers collection for the currently opened media, using script.
<Grid> <StackPanel> <TextBlock x:Name="timeTextBlock" FontSize="12">Time:</TextBlock> <TextBlock x:Name="typeTextBlock" FontSize="12">Type:</TextBlock> <TextBlock x:Name="valueTextBlock" FontSize="12">Value:</TextBlock> <Canvas> <MediaElement x:Name="media" Width="300" Height="200" MarkerReached="OnMarkerReached" Source="thebutterflyandthebear.wmv"/> </Canvas> </StackPanel> </Grid>