Lions, and Tigers, and Guids... oh my!

Everything in Project Server and SharePoint have Guids associated with them. A friend asked about generating new unique Guids for repeatable deployments. So of course I started writing a little console application to use System.Guid to generate the new Guid (I’m a developer, I always think in code). But as I started thinking about emailing an exe, an idea struck me... PowerShell. I had installed PowerShell months ago because I was told about using it to maintain my 20,000+ (and always growing) photo collection. But have never got around to using it. I fired up the console and the User Guide. I looked through the TOC and found "Working with Objects." Within 10 minutes I had figured out the syntax. So, cut to the chase...

[System.Guid]::NewGuid().ToString()

 

I have one word for this... SWEET! I look forward to playing with PowerShell more in the future.