Filter SharePoint log entries
I often end up in the event log with SharePoint problems—since there is so much goodness there… well, usually too much. So this trick of using PowerShell to filter the results and export them to a grid or CSV is very useful.
Get the 20 newest SharePoint logs to a grid:
Get-EventLog –LogName Application –Source '*sharepoint*' –Newest 20 | Out-GridView
Export all SharePoint logs to CSV (perfect for Excel):
Get-EventLog –LogName Application –Source '*sharepoint*' | Export-Csv c:\eventlog.csv