AGB  ·  Datenschutz  ·  Impressum  







Anmelden
Nützliche Links
Registrieren
Zurück Delphi-PRAXiS Programmierung allgemein Win32/Win64 API (native code) Delphi Message Text Files (Ereignisanzeige)
Thema durchsuchen
Ansicht
Themen-Optionen

Message Text Files (Ereignisanzeige)

Ein Thema von RuX · begonnen am 21. Jul 2004 · letzter Beitrag vom 22. Aug 2004
Antwort Antwort
RuX

Registriert seit: 21. Jul 2004
Ort: Nürnberg
115 Beiträge
 
Delphi 7 Architect
 
#1

Message Text Files (Ereignisanzeige)

  Alt 21. Jul 2004, 16:01
Ich bin z. Zt. auf der Suche nach einem funktionierenden Beispiel der Message Text Files. Ich brauche sie um die Fehlerdefinitionen der Eventlogs darin zu speichern. Nach MSDN Vorgaben (http://msdn.microsoft.com/library/de...text_files.asp) funktioniert es leider nicht, der message compiler von ms (mc.exe) bringt dann einen "invalid character" Fehler, das gleiche mit dem Hauseigenen MSDN Beispiel (http://msdn.microsoft.com/library/de..._text_file.asp).
Kennt sich jemand damit aus?
  Mit Zitat antworten Zitat
Blutiger Anfänger
(Gast)

n/a Beiträge
 
#2

Re: Message Text Files (Ereignisanzeige)

  Alt 22. Aug 2004, 00:10
Im PSDK gibts die zuhauf.

Hier ein Beispiel von mir welches funktioniert. Das erzeugt durch den MC eine .bin-Datei und diese wird einfach in ein .rc-Script eingebunden.

Code:
MessageIdTypedef=DWORD
SeverityNames=(
               Success         =0x0:STATUS_SEVERITY_SUCCESS
               Informational   =0x1:STATUS_SEVERITY_INFORMATIONAL
               Warning         =0x2:STATUS_SEVERITY_WARNING
               Error           =0x3:STATUS_SEVERITY_ERROR
              )

FacilityNames=(
  System=0x0FF
  Application=0xFFF
 )

LanguageNames=(English=0x409:MSG00409)

; /****************************************************************************
;  Messages
; ****************************************************************************/

MessageId=0x001
Severity=Error
Facility=Application
SymbolicName=MSG_CFG_SYNTAX_WRONGIDENTIFIER
Language=English
Syntax error: Found unknown identifier token on line %1.
.

MessageId=0x002
Severity=Error
Facility=Application
SymbolicName=MSG_CFG_SYNTAX_UNSPECIFIC
Language=English
Syntax error: Unspecific error on line %1.
.

MessageId=0x003
Severity=Error
Facility=Application
SymbolicName=MSG_CFG_SYNTAX_ILLEGALTOKEN
Language=English
Syntax error: There was an illegal token found at line %1 which is not expected outside the MAIN or MAC blocks.
.

MessageId=0x004
Severity=Error
Facility=Application
SymbolicName=MSG_CFG_SYNTAX_OPENSTRING
Language=English
Syntax error: There is an open string on line %1. Please correct this. The only valid delimiter for strings is the double quote.
.

MessageId=0x005
Severity=Error
Facility=Application
SymbolicName=MSG_CFG_SYNTAX_CLOSEDSTRING
Language=English
Syntax error: There is an closed string on line %1, but it was not opened anywhere. Please correct this. The only valid delimiter for strings is the double quote.
.

MessageId=0x006
Severity=Warning
Facility=Application
SymbolicName=MSG_CFG_SYNTAX_STRINGID
Language=English
Syntax error: Expecting a string for identifier %1 on line %2. Please enclose this string in double quotes.
.

MessageId=0x007
Severity=Error
Facility=Application
SymbolicName=MSG_CFG_SYNTAX_CONTAIN
Language=English
A block of type "%1" must not contain a block of type "%2". Correct this at line %3.
.

MessageId=0x008
Severity=Error
Facility=Application
SymbolicName=MSG_CFG_SYNTAX_CLOSEDBLOCK
Language=English
Syntax error: Only open blocks can be closed. Check line %1!
.

MessageId=0x009
Severity=Error
Facility=Application
SymbolicName=MSG_CFG_SYNTAX_LEAVEWRONG
Language=English
A block of type "%1" must not be closed as a block of type "%2". Correct this at line %3.
.

MessageId=0x00A
Severity=Error
Facility=Application
SymbolicName=MSG_CFG_SYNTAX_MALFORMED
Language=English
Syntax error: Malformed line %1. Maybe the trial to put blocks into each other?!
.

MessageId=0x00B
Severity=Error
Facility=Application
SymbolicName=MSG_CFG_SYNTAX_MALFORMEDMAC
Language=English
Syntax error: Malformed MAC "%1" on line %2. The syntax is XX-XX-XX-XX-XX-XX, where X are hexadecimal digits!
.

MessageId=0x015
Severity=Error
Facility=Application
SymbolicName=MSG_LOG_COULDNOT
Language=English
Could not log the following event to the logfile "%1".
Please check the logfile location for write protection or too restrictive permission!
Make sure the directory exists!
Here's the log string: |%2|
.

MessageId=0x020
Severity=Error
Facility=Application
SymbolicName=MSG_CFG_FILE_NOTFOUND
Language=English
The configuration file could not be found.
It was expected to be in this location:
"%1".
The path is determined by the value of "DatabasePath" in the server registry key!
.

MessageId=0x040
Severity=Informational
Facility=Application
SymbolicName=MSG_DLL_SERVICE
Language=English
The MACkerer2 DLL %1 its work! Because the DHCP daemon was %1.
.

MessageId=0x060
Severity=Informational
Facility=Application
SymbolicName=MSG_DLL_REFRESHEVENT
Language=English
A refresh of the configuration file was requested.
.
Natürlich mußt du die .h-Datei danach noch nach Delphi übertragen. Läßt sich aber zB per Perl skripten.
  Mit Zitat antworten Zitat
Antwort Antwort


Forumregeln

Es ist dir nicht erlaubt, neue Themen zu verfassen.
Es ist dir nicht erlaubt, auf Beiträge zu antworten.
Es ist dir nicht erlaubt, Anhänge hochzuladen.
Es ist dir nicht erlaubt, deine Beiträge zu bearbeiten.

BB-Code ist an.
Smileys sind an.
[IMG] Code ist an.
HTML-Code ist aus.
Trackbacks are an
Pingbacks are an
Refbacks are aus

Gehe zu:

Impressum · AGB · Datenschutz · Nach oben
Alle Zeitangaben in WEZ +1. Es ist jetzt 10:17 Uhr.
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024 by Thomas Breitkreuz