Welcome to MSDN Blogs Sign in | Join | Help

Browse by Tags

All Tags » Microcode   (RSS)

Microcode: PowerShell Scripting Trick: Fun With Parameter Binding: The Fake Parameter Set Trick

I’ve been hearing a lot of questions recently about what things you can do with advanced functions.  People seem to be aching for good examples of using PowerShell V2 functions, and, since I’ve discovered a few handy tricks for advanced functions,

Microcode: A Quick Trick to turn regular XML into Xaml

MSDN has tons of examples about XAML. Nearly everything in WPF has an example in XAML, but not all of these XAML examples actually reference the namespace that is required for this Xaml to be loadable by WPF. It's still valid XML, just not valid XAML.

Microcode: PowerShell + XNA: New-SpriteFont

As I said in a previous post, I've started to explore the wild world of XNA . XNA just released version 3, which allows you to make games for Windows, Xbox, and Zune. The SDK is free, and you can download it here . The last post introduced Get-Font ,

Microcode: PowerShell Scripting Tricks: Get-Font

I've started to explore the wild world of XNA . XNA just released version 3, which allows you to make games for Windows, Xbox, and Zune. The SDK is free, and you can download it here . It comes with a nifty little platformer game (think a 3-screen Super

Microcode: Cool Posts: Visual Studio Tips & Tricks

Benko just posted a Visual Studio Tips & Tricks listing.  It's missing on of my favorites, which a coworker on the PowerShell team, Ibrahim Abdul Rahim, showed me: In a couple of circumstances, you'll see a red squiggle (like a syntax error)

Microcode: PowerShell Scripting Tricks: Scripting the Web (Part 3) (Resolve-Link, Get-WebPageLink)

The first post in this series was learning to crawl. I introduced Get-Web , which allows you to use System.Net.Webclient to download web sites in a variety of ways. The next post was learning to walk. I showed us Get-MarkupTag , which helps coerce parts

Microcode: PowerShell Scripting Tricks: Scripting The Web (Part 2) (Get-MarkupTag)

The first post about scripting the was a lot of waxing philosophical but little about how to extract data and give it form. There are several approaches, with various difficulties. I could build a full HTML parser and walk though object models, or I could

Microcode: PowerShell Scripting Tricks: Scripting The Web (Part 1) (Get-Web)

Several of the last posts have tackled how to take the wild world of data and start to turn it into PowerShell objects, so that it’s easier to make heads or tails out of it.  Once all of that data is in a form that PowerShell can use more effectively

Microcode: PowerShell Scripting Tricks: More Joy of Hashtables (with Get-HashtableAsObject)

I recently did two different "in depth" posts.  One on The Joy Of Hashtables and another on Select-Object versus Add-Member .  At the end of Select-Object vs Add-Member, I hinted at more convenient ways to write objects that used Script

Microcode: PowerShell Scripting Tricks: The Joy of using Hashtables with Windows PowerShell

PowerShell is full of nice little touches. While some of these touches are easy to run across, like Get-Command and Get-Help, there are also a lot of little ones that are very small changes that make working with some parts of PowerShell (and .NET) a

Microcode: PowerShell Scripting Tricks: Select-Object (Note Properties) vs Add-Member (Script Properties)

As I've said a number of times before, PowerShell's quantum leap forward is something called the Object Pipeline.  It allows you to take the results of one command and easily use them with the next, which means that each command you create becomes

Microcode: Scripting RSS Feeds with PowerShell and Microsoft.FeedsManager

PowerShell's an amazing glue language.   It can help you bring code from all corners of the earth into one environment, and then you can custom the code to be more to your liking.  While the last several entries of my blog have spent time

Microcode: PowerShell Scripting Tricks - Exploring .NET Types with a Get-Type function and Reflection

There's a simple yet powerful function that nearly everyone on the PowerShell team has written a version of.  My version is called Get-Type.  It's only a one-liner, but it's an amazing way to explore .NET and it's also an amazing example of

Microcode: All About Modules (Windows PowerShell CTP2)

In a previous post , I showed you how you can debug Windows PowerShell cmdlets and providers in Visual Studio and load them up without using installutil.exe. This very briefly touched on using the command Add-Module, in this case, to load up an assembly

Microcode: Debugging Cmdlets and Providers with Visual Studio and CTP2

In PowerShell CTP2, you have a nice cmdlet, Add-Module, that frees you from the constraints of having to declare a snapin.  By using Add-Module, you can take any old library of code and load it to find cmdlets or providers.  This means that
More Posts Next page »
 
Page view tracker