Windows – Getting Windows EventViewer CSV file from Command-line

csvwindowswmi

EventViewer in Windows has the ability to export a log to a CSV file. I would like to automatically make a backup of that log in that format (as has been done manually in the past few years). It's a standalone system that will typically not have network connectivity, so log centralization tools probably won't work.

I noticed a wmic NTEVENT command, but can't seem to get to export to CSV. Here's an example:
NTEVENT WHERE "LogFile='application' AND TimeGenerated > '20100709173000.000000-300'"

Can I get that to output to a CSV file?

Best Answer

Use psloglist from http://technet.microsoft.com/en-us/sysinternals/bb897544.aspx

It does exacty what you are asking for.