Friday, September 19, 2014

PowerShell Parse Remote Event Log Email Results

I needed a quick and easy way to parse the System Event log for a specific Event ID. If the Event was found in the last 24 hours, send me an email.

Here is what I came up with: The code will look for Event ID 26 occurrences within the past 24 hours. I limit the amount of entries parsed to 200 using the -Newest property. This saves a lot of time on the parse. If you set this thing to parse the entire system log you will be waiting a while. If we find an event email me.


Post a Comment