Log event utility will log an event to the event viewer

I often need to set up scripts or scheduled routines to run on our

servers, and have wanted a way to easily log an event to the event

viewer upon starting and completing the script. Now, I think I have

found the utility that will help me do this.

The log event(logevent.exe) utility is in the Windows 2000 Resource Kit

and it gives you the ability to easily add events to the Windows

2000/NT/XP application log. You can log errors, warnings and

informational events as part of your daily routine. This makes tracking

and monitoring much easier.

Here's how it works. I want to enter an informational event into the

application log of the event viewer every time a scheduled process

started and completed. In my script, I had a command line similar to the


logevent.exe" -m \\serverName -s I -c 1 -r "Routine Process Started" -e

500 "Script scriptname.exe has successfully started."


logevent.exe" -m \\serverName -s I -c 1 -r "Routine Process Completed"

-e 501 "Script scriptname.exe has successfully completed."

Whenever my scheduled process starts, I get an event in the application

log with event ID 500. When it's finished, I get another event in the

application log with event ID 501. All I need to do is monitor the event

log on serverName and watch for event ID

ITWorld DealPost: The best in tech deals and discounts.
Shop Tech Products at Amazon