Author Posts

February 4, 2014 at 5:42 am

Team,

Thanks in advance.

I want to export data from a csv file and create htm page published for my team for daily KPI's and it needs to be an automated process.

Any help will appreciated, i am new to powershell.

Thanks,
MS

February 4, 2014 at 5:52 am

In its most basic form, that's quite simple:

Import-Csv -Path yourCsvFile.csv |
ConvertTo-Html |
Out-File -FilePath yourNewHtmlFile.html

This example just creates a fairly bland HTML table. There are lots of little things you can do to tweak the look of the resulting HTML (including CSS code, etc.) If you click the Newsletter link along the top of this site, you'll find a link to a free eBook called "Creating HTML Reports in PowerShell."

February 4, 2014 at 9:54 am

Thanks for reply Dave. i will check that book out.