79239249

Date: 2024-11-30 09:53:04
Score: 1
Natty:
Report link

The Answer is Here: Article by Doctor Scripto and is referenced in many places for solutions to System log queries via Powershell.

get-winevent -ComputerName $CompName -FilterHashtable @{logname='system'; level=1; StartTime=(get-date).AddDays(-30) } | Format-Table -Auto -Wrap

The key is the -FilterHashtable parameter. It seems to be specifically designed to process this type of information. Furthermore, it delivers the error's Message, it runs exponentially faster!

Reasons:
  • Has code block (-0.5):
  • Self-answer (0.5):
  • Low reputation (1):
Posted by: Scy Watcher