Reading the event log

  • Thread starter Thread starter Greg Smith
  • Start date Start date
G

Greg Smith

Hi, I see you can drag and drop a machines event log onto a form. Are there
any examples out there of how to read the event log into a table?

Any help is greatly appreciated.
 
Hi,

You can read it using EventLog.Entries and insert them in a collection,
like

foreach( EventLogEntry entry in eventLog1.Entries )
arrayList1.Add ( entry.Message );

Cheers,
 
Back
Top