MCI_REWIND
Appearance
This message seeks the media to the starting position. This position is defined as the first 'playable' area, beyond any header or table-of-contents data.
Syntax
param1 ULONG ulParam1; /* Message flags. */ param2 PMCI_GENERIC_PARMS pParam2; /* Pointer to the MCI_GENERIC_PARMS structure. */
Parameters
- ulParam1 (ULONG) - input
- This parameter can contain any of the following standard flags:
- MCI_NOTIFY Posts a notification message when the action completes.
- MCI_WAIT Does not return control until the action is completed.
- pParam2 (PMCI_GENERIC_PARMS) - input
- A pointer to the default media control interface parameter data structure.
Returns
- rc (ULONG) - returns
-
- MCIERR_SUCCESS If the function succeeds.
- MCIERR_INVALID_DEVICE_ID The device ID is not valid.
- MCIERR_DEVICE_LOCKED The device is acquired for exclusive use.
- MCIERR_INVALID_FLAG Flag (ulParam1) is invalid.
- MCIERR_FLAGS_NOT_COMPATIBLE Flags cannot be used together.
- MCIERR_INVALID_CALLBACK_HANDLE The callback handle given is not correct.
Remarks
This message is the functional equivalent of the MCI_SEEK message with the `MCI_TO_START` flag specified.
Example Code
The following code illustrates how to seek the media to the starting position.
USHORT usDeviceID;
HWND hwndMyWindow;
MCI_GENERIC_PARMS mciGenericParms;
/* Generic message parms structure */
/* Assign hwndCallback the handle to the PM Window routine */
mciGenericParms.hwndCallback = hwndMyWindow;
mciSendCommand( usDeviceID, /* Device ID */
MCI_REWIND, /* MCI rewind message */
MCI_NOTIFY, /* Flag for this message */
(PVOID) &mciGenericParms, /* Data structure */
0); /* No user parm */