mciSetYieldProc

The mciSetYieldProc function sets the address of a procedure to be called periodically when an MCI device is waiting for a command to finish because the "wait" (MCI_WAIT) flag was specified.

UINT mciSetYieldProc(
  MCIDEVICEID IDDevice,  
  YIELDPROC yp,          
  DWORD dwYieldData      
);

Parameters

IDDevice

Identifier of the device to assign a procedure to.

yp

Pointer to the procedure to call when yielding for the specified device. If this parameter is NULL, the function disables any existing yield procedure.

dwYieldData

Data to be sent to the yield procedure when it is called for the specified device.

Return Values

Returns TRUE if successful or FALSE otherwise.

Remarks

This function overrides any previous yield procedure for this device.

Requirements

**  Windows NT/2000/XP:** Included in Windows NT 3.1 and later.
**  Windows 95/98/Me:** Included in Windows 95 and later.
**  Header:** Declared in Mmsystem.h; include Windows.h.
**  Library:** Use Winmm.lib.

See Also

MCI, MCI Functions