The MCI_CLOSE_DRIVER message requests an MCI driver to close a driver instance that was previously opened with an MCI_OPEN_DRIVER message.
If the close operation succeeds, the driver returns zero. Otherwise, the driver returns one of tbe MCIERR error codes defined in mmsystem.h.
A client sends the message by calling the driver’s DriverProc entry point, passing the specified parameters. When an application sends an MCI_CLOSE message, winmm.dll intercepts it and sends MCI_CLOSE_DRIVER to the driver.