Clearing an Event Log
You can use the EventLog.Clear instance method to clear an event log. You are likely to want to do this when writing a custom event log, where a lot of procedural-level entries might fill up the log. The following fragment demonstrates how to clear a specific log:
Dim Log As New EventLog("Application") Log.Clear()
Log.Clear requires no parameters because it's an instance method. The EventLog instance knows which log it's associated with.