How To Write to the Windows NT Event Log from Visual Basic (154576)
The information in this article applies to:
- Microsoft Visual Basic Learning Edition for Windows 6.0
- Microsoft Visual Basic Professional Edition for Windows 6.0
- Microsoft Visual Basic Professional Edition for Windows 5.0
- Microsoft Visual Basic Enterprise Edition for Windows 6.0
- Microsoft Visual Basic Enterprise Edition for Windows 5.0
- Microsoft Visual Basic Standard Edition, 32-bit, for Windows 4.0
- Microsoft Visual Basic Professional Edition, 32-bit, for Windows 4.0
- Microsoft Visual Basic Enterprise Edition, 32-bit, for Windows 4.0
This article was previously published under Q154576 SUMMARY
Event logging in Windows provides a standard, centralized way for Windows
and any other applications to record important software and hardware
events. It also supplies a standard user interface for viewing the logs and
a programming interface for examining the logs.
This article illustrates how to write to the NT or Windows 2000 Event Log with Visual Basic versions 4.0 and later. With Visual Basic version 4.0, you must use the Win32 API. Visual Basic versions 5.0 and later have built-in functionality for event-logging so the API functions are unnecessary.
REFERENCES
For additional information, please click the article numbers below
to view the articles in the Microsoft Knowledge Base:
184747 INFO: Event Logging in Visual Basic
161306 INFO: App.LogEvent Only Logs in Compiled Applications
161283 INFO: Default Filename for Text File Error Log: VBEVENTS.LOG
Microsoft Developer Support Network (MSDN)
Platform SDK; Reference; Functions -- Win32 Functions
Microsoft Visual Basic 5.0 Online Help
Modification Type: | Minor | Last Reviewed: | 7/15/2004 |
---|
Keywords: | kbAPI kbhowto KB154576 |
---|
|