System.Classes.EFileStreamError.Create

Aus RAD Studio API Documentation
Wechseln zu: Navigation, Suche

Delphi

constructor Create(ResStringRec: PResStringRec; const FileName: string);

C++

__fastcall EFileStreamError(System::PResStringRec ResStringRec, const System::UnicodeString FileName);
/* Exception.CreateFmt */ inline __fastcall EFileStreamError(const System::UnicodeString Msg, const System::TVarRec *Args, const int Args_High) : EStreamError(Msg, Args, Args_High) { }
/* Exception.CreateRes */ inline __fastcall EFileStreamError(NativeUInt Ident)/* overload */ : EStreamError(Ident) { }
/* Exception.CreateRes */ inline __fastcall EFileStreamError(System::PResStringRec ResStringRec)/* overload */ : EStreamError(ResStringRec) { }
/* Exception.CreateResFmt */ inline __fastcall EFileStreamError(NativeUInt Ident, const System::TVarRec *Args, const int Args_High)/* overload */ : EStreamError(Ident, Args, Args_High) { }
/* Exception.CreateResFmt */ inline __fastcall EFileStreamError(System::PResStringRec ResStringRec, const System::TVarRec *Args, const int Args_High)/* overload */ : EStreamError(ResStringRec, Args, Args_High) { }
/* Exception.CreateHelp */ inline __fastcall EFileStreamError(const System::UnicodeString Msg, int AHelpContext) : EStreamError(Msg, AHelpContext) { }
/* Exception.CreateFmtHelp */ inline __fastcall EFileStreamError(const System::UnicodeString Msg, const System::TVarRec *Args, const int Args_High, int AHelpContext) : EStreamError(Msg, Args, Args_High, AHelpContext) { }
/* Exception.CreateResHelp */ inline __fastcall EFileStreamError(NativeUInt Ident, int AHelpContext)/* overload */ : EStreamError(Ident, AHelpContext) { }
/* Exception.CreateResHelp */ inline __fastcall EFileStreamError(System::PResStringRec ResStringRec, int AHelpContext)/* overload */ : EStreamError(ResStringRec, AHelpContext) { }
/* Exception.CreateResFmtHelp */ inline __fastcall EFileStreamError(System::PResStringRec ResStringRec, const System::TVarRec *Args, const int Args_High, int AHelpContext)/* overload */ : EStreamError(ResStringRec, Args, Args_High, AHelpContext) { }
/* Exception.CreateResFmtHelp */ inline __fastcall EFileStreamError(NativeUInt Ident, const System::TVarRec *Args, const int Args_High, int AHelpContext)/* overload */ : EStreamError(Ident, Args, Args_High, AHelpContext) { }

Eigenschaften

Typ Sichtbarkeit Quelle Unit Übergeordnet
constructor public
System.Classes.pas
System.Classes.hpp
System.Classes EFileStreamError

Beschreibung

Erstellt ein neues EFileStreamError-Objekt.

Create instantiiert ein Exception-Objekt mit einem einfachen Meldungs-String. Verwenden Sie mit dem Konstruktor das Schlüsselwort throw. Beispiel:



throw EFileStreamError("My error message");



Msg ist die Fehlermeldung, die zur Laufzeit im Exception-Dialogfeld angezeigt wird.

Args ist ein Konstanten-Array mit Werten, die entsprechend den Formatbezeichnern in Msg in den String eingefügt werden.

Args_Size ist der Index der letzten Konstante in Args (Anzahl der Einträge – 1).

AHelpContext gibt die kontextbezogene Hilfe-ID für die Exception an.

Ident ist die eindeutige ID der String-Ressource für die in der RES-Datei festgelegte Fehlermeldung. Wenn Ident keine gültige Ressourcen-ID ist, erzeugt der Konstruktor einen leeren Meldungs-String für die Exception.

ResStringRec ist eine Struktur, die eine String-Ressource durch deren Modul- und Ressourcen-ID beschreibt. Sie wird hauptsächlich zusammen mit Delphi-Werten des Typs resourcestring verwendet.