다음을 통해 공유


Controls.fastForward method

[The feature associated with this page, Windows Media Player SDK, is a legacy feature. It has been superseded by MediaPlayer. MediaPlayer has been optimized for Windows 10 and Windows 11. Microsoft strongly recommends that new code use MediaPlayer instead of Windows Media Player SDK, when possible. Microsoft suggests that existing code that uses the legacy APIs be rewritten to use the new APIs if possible.]

The fastForward method starts fast play of the media item in the forward direction.

Syntax

Controls.fastForward()

Parameters

This method has no parameters.

Return value

This method does not return a value.

Remarks

The fastForward method plays the clip back at five times the normal speed. Invoking fastForward changes the Settings.rate property to 5.0. If rate is subsequently changed, or if play or stop is called, Windows Media Player will cease fast forwarding.

The fastForward method does not work for live broadcasts and certain media types. To determine whether you can fast forward in a clip, call isAvailable("FastForward").

Examples

The following example creates an HTML BUTTON element that uses fastForward to start fast play of the media item. The Player object was created with ID = "Player".

<INPUT TYPE = "BUTTON"  ID = "FF"  NAME = "FF"  VALUE = ">>"  

    /* Execute JScript when the BUTTON is clicked. 
       Check first to make sure fast-forward mode is available
       for this particular media item */
    onClick = "if (Player.controls.isAvailable('FastForward'))
        Player.controls.fastForward();
">

Requirements

Requirement Value
Version
Windows Media Player version 7.0 or later.
DLL
Wmp.dll

See also

Controls Object

Controls.isAvailable

Controls.play

Controls.stop

Settings.rate