Recently I was Reading a write-up on API and transforming data with Python.
I know this is a blog about PowerShell right? However I want to point out that python is a scripting environment and actually more involved to get started so the restraints of that for a beginner is constricting (Pun intended).
PowerShell is on every windows computer since windows XP and PowerShell version 7.0 is now available for install on all Major OS including Mac, Linux and even IoT and its backwards compatible to windows 7.
If you are interested in a python project go here, because it will satisfy your needs and also take hours!
I will however show you how to do it with Html and Excel.
The First way is with an additional module known as “importExcel” (the link to the psgallery details is there)
Truth be told you can also Export to excel as well even though the name doesn’t give that away.
Let’s install it, we will do it in a way that is allowed if you don’t have local admin rights on your PC.
Install-Module -Name importexcel -Scope CurrentUser Import-module importexcel Thus your environment is ready for the next commands.
get-service | where -property status -eq running |select name,status,starttype |Export-Excel -Path $home\documents\TestExport.xlsx -Show -Title "Running Services" -TableStyle Dark10 -AutoSize
This is how you can start reporting and looking professional and save the formatting steps.
See the next post to see how we tie performance metric to Excel reporting.