The MCIWndGetError macro retrieves the last MCI error encountered. You can use this macro or explicitly send the MCIWNDM_GETERROR message.
LONG MCIWndGetError(
hwnd,
lp,
len
);
Returns the integer error value if successful.
If lp is a valid pointer, a null-terminated string corresponding to the error is returned in its buffer. If the error string is longer than the buffer, MCIWnd truncates it.
Windows NT: Requires version 3.1 or later.
Windows: Requires Windows 95 or later.
Windows CE: Unsupported.
Header: Declared in vfw.h.
MCIWnd Window Class Overview, MCIWnd Macros, MCIWNDM_GETERROR