Windows Media Player 11 SDK Controls.currentPositionStringĀ 

Windows Media Player SDK banner art

Previous Next

Controls.currentPositionString

The currentPositionString property retrieves the current position in the media item as a String formatted as HH:MM:SS (hours, minutes, and seconds).

Syntax

  
    
  

Possible Values

This property is a read-only String.

Remarks

If the media item is less than an hour long, the HH: portion is not included.

Example Code

The following JScript example starts an HTML timer that displays the current position of the media file at one-second intervals. An HTML TEXT element named MyText was created to display the current position. The Player object was created with ID = "Player".

  

****Note   ****You should include code to stop the timer when the media item is stopped or paused.

Requirements

Version: Windows Media Player version 7.0 or later.

Library: Use wmp.dll.

See Also

Previous Next