Learn about Windows PowerShell
Good morning. The Scripting Wife here. The Microsoft Scripting Guy claims he is working. I am not sure how he can do that with his Zune blasting the Rolling Stones. I swear the FCC is going to come break down our front door one of these days and charge him with broadcasting without a license.
Anyway, he says he is too busy to work with me as I learn Windows PowerShell. Something about people from all over the world working on the 2010 Scripting Games. I tell you what, he gets so dramatic sometimes. Today’s script was easy. I had to find an event in the event log that told when the event log started. I knew I would need to use the Get-Eventlog cmdlet to do that. I read through the help by using Help Get-EventLog to see what options were available. Next, I used the up arrow, and added the –full parameter so that I could read about the parameters and see examples of how to use the command. The help command looked like this: Help Get-EventLog –full. You can see it in the following screen shot.
After I saw that, it was a piece of cake to get my script working. Okay, it’s a single line, but really, it works. So what if it only took me about 15 minutes to get it to work? Isn’t that the point of Windows PowerShell in the first place? To get it done without having to write a lot of boring code? I posted my script on PoshCode.
Since the Script Monkey is locked in his cage, I think I will call a couple of my friends and go shopping. Look for me tomorrow if I make it back in time for Event 3. What happened to Event 1? That was sooooo yesterday. I did something, but I don’t remember. It’s on PoshCode as well. I’m gonna e-mail this to the Microsoft Scripting Guy, and I am outta here.
Microsoft Scripting Guy Ed Wilson here. Now that the Scripting Wife is out of my hair, let me invite you to keep up with the 2010 Scripting Games by following us on Twitter or Facebook. If you have any questions during the Games, send e-mail to us at email@example.com or post your questions on the 2010 Scripting Games forum. See you tomorrow. Until then, peace.
Ed Wilson and Craig Liebendorfer, Scripting Guys
I can't see the script you wrote, could you post it here?
@conkil The Scripting Wife wrote this post prior to the end of the event, and therefore, she did not post her solution. However, all of the solutions are on PoshCode.