EventLog.Write
Top  Previous  Next


Writes to the application event log on the local machine

Category
Event log

Script section
All

EventLog.Write Type, EventID, Description

Type
Type of event to write, options: Information | Warning | Error  
·Information - write information event  
·Warning - write warning event  
·Error - write error event  

EventID

770-779  

Description

Text to write to the event log (keep it short). Tabs and commas are not allowed.  
 
Notice: the message table is located in the DLL file "esource.dll" - descriptions written with AdmWin will not be displayed correctly when AdmWin is uninstalled and "esource.dll" is removed.  

Example
Log a warning with EventID 776 when current script fails

[OnError_Batch_Begin]
EventLog.Write Warning, 776, %LastErrorCommand% - %LastErrorMsg%
[OnError_Batch_End]