HOWTO: How to Support Language-Independent Strings in Event Logging |
Q125661
Insertion strings in the event log entries are language-independent. Instead of using string literals as the insertion string, use "%%n" as the insertion string.
When the event viewer sees "%%n", it looks up the ParameterMessageFile value in the registry, under the source of the event, as in this example:
HKEY_LOCAL_MACHINE\SYSTEM\
CurrentControlSet\
Services\
EventLog\
Security\
...
-or-
HKEY_LOCAL_MACHINE\SYSTEM\
CurrentControlSet\
Services\
EventLog\
System\
Service Control Manager
It then calls the LoadLibrary() function of the ParameterMessageFile. Then
it calls FormatMessage() using "n" as the ID.
and the description isService Control Manager
In the registry, you find:Failed to start the service due to the following error: %%245.
HKEY_LOCAL_MACHINE\SYSTEM\
CurrentControlSet\
Services\
EventLog\
System\
Service Control Manager
EventMessageFile...
ParameterMessageFile REG_SZ kernel32.dll
TypesSupported...
...
Therefore, you need to follow these steps:
Additional query words: 3.10 3.50
Keywords : kbEventLog kbKernBase kbOSWin2000 kbDSupport kbGrpDSKernBase
Issue type : kbhowto
Technology : kbAudDeveloper kbWin32sSearch kbWin32API
|
Last Reviewed: October 23, 2000 © 2001 Microsoft Corporation. All rights reserved. Terms of Use. |