Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Deleting event viewer logs by using VB..

Status
Not open for further replies.

ashvn

Programmer
Mar 21, 2001
33
MU
Hi!

How can I clear event viewer logs by using VB?

Thanks a lot!!
:)
 
ashvn

You need to look up the following API calls

OpenEventLog - To get handle to event log (either Local or remote
ClearEventLog - Clears Eventlog
CloseEventLog - to clear up after yourself...

It is a relatively simple process...

If you want to read the event log, there is some proof of concept code written by strongm around. A search of this forum shoudl find it!

Take Care

Matt
If at first you don't succeed, skydiving is not for you.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top