다음을 통해 공유


CurrentPosition (Windows CE 5.0)

Send Feedback

This property specifies the clip's current position, in seconds. This property is read/write.

Compatibility: Windows Media Player, ActiveMovie

MediaPlayer.CurrentPosition [ =dblPosition]

Parameters

  • dblPosition
    Double value representing the clip's current position, in seconds. There is no default value.

Remarks

The value of this property is a new position within the clip, in seconds.

Setting this property at run time is similar to performing a seek operation, and changes the position to the specified point in the clip. The new value must be within the range specified by the SelectionStart and SelectionEnd properties.

Before attempting to set this property, determine the length of the file in seconds by retrieving the value of the Duration property.

Before the FileName property is set, CurrentPosition returns -1 (minus one).

The following code example shows how to use the CurrentPosition property to rewind a clip after it has been stopped.

MediaPlayer1.Stop( );
MediaPlayer1.CurrentPosition = 0;

ActiveMovie compatibility mode is only supported through Windows CE 4.1.

Requirements

OS Versions: Windows CE 3.0 and later.

See Also

Windows Media Player Properties | Compatibility Modes | Playback Methods and Properties

Send Feedback on this topic to the authors

Feedback FAQs

© 2006 Microsoft Corporation. All rights reserved.