Skip to main content

Posts

Showing posts from September, 2014

PowerShell + SCCM - POSH Deploy v1

I wrote an article for the coveted PowerShell Magazine on how to automate query based deployments in ConfigMgr using PowerShell. http://www.powershellmagazine.com/2014/07/22/automating-deployments-in-configuration-manager-with-powershell/ If you go through that article you will get a background of this post. So continuing to that, I present " POSH Deploy v1 " which can be used to automate Query Based deployments with Configuration Manager (tested it on CM 2012 only). I had a similar tool built in my previous project for SCCM 2007 but that one had a lot of hard coded values, tried to remove those. The tool earlier used Winforms and this time I kicked myself to try out WPF with PowerShell . Thanks to StackOverflow and blog posts shared around these topics by awesome community people :)

PowerShell + WPF + GUI : Hide (Use) background PowerShell Console

Few years back, I had started wrapping my PowerShell scripts with some sort of GUI built using Windows Forms (used Primal Forms CE mostly). Things went fine for a while but then I stumbled across awesome posts by MVP Boe Prox on using WPF with PowerShell to do the same. (check Resources section) I had been procrastinating the idea of playing with WPF for a while but then had a great discussion with MVP Chendrayan (Chen) and got inspired to do it. One can use Visual Studio (Express Edition - which is free) to design the UI and then consume the XAML in PowerShell script...Isn't that Cool ! See resources section for links on that. Often when we write the Code to present a nice UI to the end user there is a PowerShell console running in the background. In this post I would like to share a trick to hide/show the background console window. This trick works with both Winforms and XAML. Note - PowerGUI & Visual Studio Express are absolutely FREE ! For the demo of thi