List of EventIDs from the Event Log

  • Thread starter Thread starter UJ
  • Start date Start date
U

UJ

Does anybody know of where I can find a complete list of the events that
Windows writes to the EventLog ?

TIA - Jeff.
 
Jeff,

You can get the EventLog instance for the event log that you are trying
to cycle through. Then, check the Events property. It returns a
EventLogEntryCollection class instance which you can iterate through and get
the EventLogEntry instances (representing entries in the log). From that,
you can use the InstanceId property to get the id of the event.

Hope this helps.
 
No. What I mean is I've got the events I know I'm going to be searching for,
I just at the moment don't know what the event ID is for that event.

For instance - I want to know when a machine shutdown. That would be eventID
........ ????? What I need is the list of event IDs that can be
written to the eventlog so that I can figure out what event ID I need to
look for.

TIA - Jeff.

Nicholas Paldino said:
Jeff,

You can get the EventLog instance for the event log that you are trying
to cycle through. Then, check the Events property. It returns a
EventLogEntryCollection class instance which you can iterate through and
get the EventLogEntry instances (representing entries in the log). From
that, you can use the InstanceId property to get the id of the event.

Hope this helps.


--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)

UJ said:
Does anybody know of where I can find a complete list of the events that
Windows writes to the EventLog ?

TIA - Jeff.
 
Jeff,

Ahh, I don't know of a list offhand. I would just look for the event in
the event log and then copy down the event log name, the source, and the
event id.


--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)

UJ said:
No. What I mean is I've got the events I know I'm going to be searching
for, I just at the moment don't know what the event ID is for that event.

For instance - I want to know when a machine shutdown. That would be
eventID ....... ????? What I need is the list of event IDs that
can be written to the eventlog so that I can figure out what event ID I
need to look for.

TIA - Jeff.

Nicholas Paldino said:
Jeff,

You can get the EventLog instance for the event log that you are
trying to cycle through. Then, check the Events property. It returns a
EventLogEntryCollection class instance which you can iterate through and
get the EventLogEntry instances (representing entries in the log). From
that, you can use the InstanceId property to get the id of the event.

Hope this helps.


--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)

UJ said:
Does anybody know of where I can find a complete list of the events that
Windows writes to the EventLog ?

TIA - Jeff.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top