Revisiting Old Posts: Get-Process | Dir (about ValueFromPipelineByPropertyName)

A number of PowerShell MVPs and PowerShell team members are helping me to compile a table of contents for our blog, which basically means that I’m getting to go back and revisit all of the fun stuff posted to the PowerShell blog over the past few years.  It’s a fun an educational process, and, hopefully,… Read more

Programming PowerShell_ISE

I recently wrote a blog Powershell_Ise Can Do a Lot More Than You Think where I described the ability to program it to do new stuff.  Karl Prosser has picked up the baton and written some cool scripts programming the PowerShell_ISE to make it do some of the features that he had put into his… Read more

Diagnosing Here-Strings With PowerShell_ISE

James Brundage posted a blog entry How To Write a Console Application in PowerShell with Add-Type which used a here-string.   One user (lcr) copied and pasted the text and got the following error: Unrecognized token in source text. At line:1 char:72 + Add-Type -OutputType ConsoleApplication -OutputAssembly HelloWorld.exe  < <<< @"     + CategoryInfo          : ParserError:… Read more

How To Write a Console Application in PowerShell with Add-Type

Windows PowerShell CTP3 has a lot of very cool things.  CTP2 introduced the Add-Type cmdlet, which allowed you to dynamically compile C# in PowerShell.  It was actually possible to use the CompilerParameters to Add-Type to make a console application, but it wasn’t particularly easy.  In CTP3, we’ve made this a lot easier to do. There’s… Read more


.cmdletname { font-size:large } .cmdletsynopsis { font-size:medium } .cmdletdescription { font-size:medium } .cmdletparameters { font-size:medium } th { font-size: medium; font-style: italic } table { border: 1 } When I write a PowerShell function, I try to ensure that it follows the PowerShell standard verbs. These verbs actually exist as static properties in a few… Read more

How and Why to Use Splatting (passing [switch] parameters)

On our internal discussion list, someone just asked about how to pass switch parameters from one function to another.  This person asked this as "Why can’t [switch] parameters be passed as parameters?". My short answer was simple: "They Can Be" Answering this question is a great way to illustrate the value of a PowerShell V2… Read more

A Module to Create Modules and Advanced Functions

[1/3/09 Update – the original link to the attachment containing this code was broken but is now fixed.  Sorry. jps] It is hard to overstate how important Modules and Advanced Functions are.   If you are a PowerShell user – you need to take the time to learn these new mechanisms and use them as your first choice… Read more