Share via


Windows Media Player 11 SDK IWMPControls.fastReverse (VB and C#) 

Windows Media Player SDK banner art

Previous Next

IWMPControls.fastReverse (VB and C#)

The fastReverse method starts fast play of the media item in the reverse direction.

  

Parameters

This method takes no parameters.

Return Value

This method does not return a value.

Remarks

The fastReverse method scans the clip in reverse at five times the normal speed, displaying only the key frames if it is a video file. Calling fastReverse is equivalent to specifying -5.0 for the rate by setting the IWMPSettings.rate property. If the rate is subsequently changed, or if IWMPControls.play or IWMPControls.stop is called, Windows Media Player will cease fast reverse.

If the item is part of a playlist, fastReverse stops at the beginning of the current track. For instance, if track 3 is in fastReverse, when the beginning of track 3 is reached, Windows Media Player will not go to track 2. The play count is not incremented when calling fastReverse.

If you call IWMPControls.fastForward while fastReverse is running, fastReverse will be stopped and IWMPControls.fastForward will begin.

This method does not work for live broadcasts and certain digital media types. To determine whether you can use fast reverse in a clip, pass the System.String value "FastReverse" to the IWMPControls.isAvailable property (the IWMPControls.get_isAvailable method in C#).

Example Code

The following example uses fastReverse to reverse the current media item in response to the Click event of a button. The AxWMPLib.AxWindowsMediaPlayer object is represented by the variable named player.

  
Public Sub fastReverseButton_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles fastReverseButton.Click

    ' To get all of the available functionality of the player controls, Dim the
    ' value returned by player.Ctlcontrols as a WMPLib.IWMPControls3 interface.
    Dim controls As WMPLib.IWMPControls3 = player.Ctlcontrols

    ' Check first to be sure the operation is valid.
    If (controls.isAvailable("fastReverse")) Then

        controls.fastReverse()

    End If

End Sub

FakePre-0915dd65450341b3b0ac59066029f328-bfa312fe19e740ae9ac8a968b5744d0a

private void fastReverseButton_Click(object o, System.EventArgs args)
{
    // To get all of the available functionality of the player controls, cast the
    // value returned by player.Ctlcontrols to a WMPLib.IWMPControls3 interface. 
    WMPLib.IWMPControls3 controls = (WMPLib.IWMPControls3)player.Ctlcontrols;

    // Check first to be sure the operation is valid.
    if (controls.get_isAvailable("fastReverse"))
    {
        controls.fastReverse();
    }
}

Requirements

Version: Windows Media Player 9 Series or later

Namespace: WMPLib

Assembly: Interop.WMPLib.dll (automatically generated by Visual Studio)

See Also

Previous Next