How to Perform Auto Repeat as Media Player Does

Article translations Article translations
Article ID: 124185 - View products that this article applies to.
This article was previously published under Q124185
The Media Player (MPLAYER.EXE) included with Microsoft Windows and Microsoft Windows NT (MPLAY32.EXE) provides an auto-repeat option that automatically repeats the playback of a multimedia file. You can incorporate this functionality into your application on Digital Video devices by using an extension to the standard Media Control Interface (MCI) commands as follows:

  • When calling the mciSendString() function, add the word "repeat" to the play command, as in this example:
    mciSendString("play mov notify repeat", NULL, 0, hWnd);
    			
  • When calling the mciSendCommand() function, set the play flag MCI_DGV_PLAY_REPEAT. For example, to add auto repeat functionality to the MOVPLAY sample included with the Video for Windows DK, add the following line to the playMovie() function in MOVPLAY1.C, right before the mciSendCommand() function call:
    dwFlags |= MCI_DGV_PLAY_REPEAT;
    			
"Digital Video Command Set for the Media Control Interface" documents the Digital Video MCI extensions. It is available on the Microsoft Developer Network (MSDN) CD. Look for it in the Specifications section of the CD contents, under "Digital Video MCI Specification." You can also search the CD using the word MCI_DGV_PLAY_REPEAT for more information about that flag.
Expand all | Collapse all

Properties

Article ID: 124185 - Last Review: May 11, 2007 - Revision: 4.3
APPLIES TO
  • Microsoft Video for Windows Development Kit 1.1
  • Microsoft Platform Software Development Kit-January 2000 Edition, when used with:
    • Microsoft Windows 3.1 Standard Edition
    • Microsoft Windows 3.11 Standard Edition
    • Microsoft Windows NT Advanced Server 3.1
    • Microsoft Windows NT Server 3.5
    • Microsoft Windows NT Server 3.51
    • Microsoft Windows NT Server 4.0 Standard Edition
    • Microsoft Windows NT Workstation 3.1
    • Microsoft Windows NT Workstation 3.5
    • Microsoft Windows NT Workstation 3.51
    • Microsoft Windows NT Workstation 4.0 Developer Edition
Keywords: 
KB124185

Give Feedback

 

Contact us for more help

Contact us for more help
Connect with Answer Desk for expert help.
Get more support from smallbusiness.support.microsoft.com