General discussion

Locked

Writing to the Event Log

By gary ·
Does anyone know of a command line utility that will allow a batch file or similar to write an entry to the event log?

I'm looking to automate some daily tasks on a couple of NT servers and it would be a very big bonus to be able to write information into the event log which can be viewed the same as other entries.

Thanks,

--
Gary Williams

This conversation is currently closed to new comments.

3 total posts (Page 1 of 1)  
| Thread display: Collapse - | Expand +

All Comments

Collapse -

Writing to the Event Log

by DAO251 In reply to Writing to the Event Log

Gary,

I would recommend you downloading Windows Script Host (WSH) and using JScript/VBScript programs instead of batch files.

WSH provides WshShell object having LogEvent method, which does exactly what you want.

You can download that fromMS website:
http://msdn.microsoft.com/scripting

HTH,

Dima Oussevitch
Brainbench MVP for WinNT Admin
http://www.brainbench.com

Collapse -

Writing to the Event Log

by gary In reply to Writing to the Event Log

Thanks,

I suspected that scripting may be the better option but I've not used it before - Good time to learn I guess!!!

Collapse -

Writing to the Event Log

by gary In reply to Writing to the Event Log

This question was closed by the author

Back to Windows Forum
3 total posts (Page 1 of 1)  

Related Discussions

Related Forums