Registriert seit: 26. Aug 2003
Ort: Steinfurt
292 Beiträge
Delphi XE2 Professional
|
Re: "Delphi"-Exceptions verhindern
22. Okt 2003, 15:05
Delphi-Quellcode:
procedure TForm1.HandleMCIDeviceError;
begin
ShowMessage('Mist!');
Form1.MediaPlayer1.Close;
end;
procedure TForm1.Button1Click(Sender: TObject);
begin
try
MediaPlayer1.Open;
except
on E: EMCIDeviceError do HandleMCIDeviceError;
end;
end;
Debuggers don't remove Bugs, they only show them in Slow-Motion.
|