Previous: 4.47.1.1. AutoRewind To the Table of Contents Next: 4.47.1.3. Notify
4.47.1.1. AutoRewind Table of Contents 4.47.1.3. Notify

- 4.47.1.2. -
Table of Contents
4. Standard Units
4.47. MMedia - Multimedia Devices support unit
4.47.1. TMMedia Object Fields
4.47.1.2. MCErrorProc


4.47.1.2. MCErrorProc

Targets: Win32 only


MMedia Unit

Points to the error handler procedure, which gets called when the TMMedia object tries to open non-supported media files. This procedure will be also called every time the TMMedia object tries to perform any operation if the media device has not been previously open.

Declaration:
  MCIErrorProc: procedure (ErrorCode: UINT);
Remarks: By default the MCIErrorProc points on following error handler procedure:
procedure DefaultMCIErrorProc(ErrorCode: UINT);
var
  Temp: array [0..MAX_PATH] of char;

begin
  if isConsole then 
    Writeln('MCI device fault. Error code #' + IntToStr(ErrorCode))
  else
    MessageBox(0, StrPCopy(Temp, 'MCI device fault. Error code #'
               + IntToStr(ErrorCode)), 'Error', MB_ICONERROR);
end;



Previous: 4.47.1.1. AutoRewind To the Table of Contents Next: 4.47.1.3. Notify
4.47.1.1. AutoRewind Table of Contents 4.47.1.3. Notify

- 4.47.1.2. -