![]() |
Raise - Befehl
Hallo
Ich habe folgendes Problem mit dem raise - Befehl: In Indy wir an seeeeeeeeeeeeeehr vielen Stellen eine Exception ausgeführt. Beispiel:
Delphi-Quellcode:
Ok, ich versuche diesen Fehler abzufangen:
raise EIdSocketError.CreateError(AErr, WSTranslateSocketErrorMsg(AErr));
Delphi-Quellcode:
Leider wird mir die Fehlermeldung trotzdem angezeigt. Wie kann ich das verhindern? (Nein, ich will nicht das ganze Indy ändern und try ... except einbauen :) )
constructor EIdException.Create(const Msg: string);
begin if Assigned(vIndyException) then if Assigned(vIndyException.OnError) then vIndyException.OnError(IdErrorUnknown,Msg); end; Gruß Onz |
Re: Raise - Befehl
Die Fehler werden nur in der Entwicklungsumgebung angezeigt. Irgendwo in den Optionen kannst du das abstellen. Aber wie schon gesagt, wenn du das programm außerhalb von delphi ausführst sind fast alle indyexceptions weg
|
Re: Raise - Befehl
Hallo
Bitte weg von Indy :) Das war nur als Beispiel für meine Situatuion. Ich will im TException - Creator den Fehler abfagnegn und KEINE Excpetion auslösen. Gruß |
Re: Raise - Befehl
versuchs mal mit
Applicaiton.onException |
Re: Raise - Befehl
Das will ich ja auch vermeiden :)
Gruß |
Re: Raise - Befehl
ich würd mal behaupten das ist so gut wie unmöglich da durch den construct von Exception das ganze ja schon ausgelöst wird und die Routine die du ins Create machst da immer zu spät kommt
|
Alle Zeitangaben in WEZ +1. Es ist jetzt 13:43 Uhr. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024 by Thomas Breitkreuz