I can get errors from the event log like this: Get-Eventlog system -Newest 1000 -ComputerName $Machine | where {$_.entryType -Match "Error"} this gives me errors but not from the location I need.
I can also change system to application, security or setup. My issue is I need to get log file information from Event Viewer \ Applications and Services Logs \ Microsoft \ Group Policy \ Operational
I know from my own machine I have an error in this log location with an Event ID of 7007. I've tried to run this and it fails. get-eventlog -log system -source 'group policy' | where {$_.eventID -eq 7007}
How can I extract out "all" errors, warnings from this Operational log file location?