Scripting Wife comments on 2011 Scripting Games event 8

Good morning everyone … and yes I said morning. The Scripting Guy and I are up early this morning. He is busy packing, and so I thought I would hop into his office and give you my impression of beginner event 8. Why am I up so early you may ask? Well we are on our way to Vegas for the PowerShell Deep Dive. It will be a rather long flight for us – in the neighborhood of four hours, but that is ok because our seats are at opposite ends of the plane. He is in an exit row, and I am riding on the tail flaps I guess. He will not even miss me during the flight – what with his Zune, and his laptop he will spend most of the trip writing PowerShell scripts. Me? I will be reading a nice book (assuming the wind does not blow it out of my hands).

Anyway, allow yourself ample time to write the script for event 8. It is kind of strange that there is no cmdlet that will tell me information about disk drives … so I had to resort to using WMI. I know the Scripting Guy has written a lot about disk drives, but there is a lot of stuff to read through, and so I just went to MSDN and using Bing searched for disk drive space. I know that is not a great search, but I found information about WMI and disks on that page, so as I always say, “any search that returns what you need is a good search.” Once you have found the disk information, the rest is really easy. I used the Get-Command cmdlet to look for cmdlets  that have a noun that is something like a CSV, so that I could pipeline my output to a CSV file. The really cool thing I have learned about CSV files is if you double click them they open in Microsoft Excel. Because I used to do Accounting, I LOVE Microsoft Excel!!! And the fact that there is a cmdlet that virtually creates Microsoft Excel spreadsheets … well at the risk of sounding too much like a geek (like the Scripting Guy) this is cool stuff. Hope you are having fun and learning a lot of useful information in the 2011 Scripting Games. Have a scriptastic day.


Comments are closed. Login to edit/delete your existing comments