Tag Archives: powergui

PowerGUI® Pro and PowerGUI® 3.0 Released

Having been using the beta for a while, I was very pleased to see that PowerGUI V3 has been released. Some of the new features / fixes that I like the best are:

  • Create Executable from Script
  • One click install for PowerPacks
  • PowerCLI 4.1 Support in the VMware PowerPack

Have a look at Kirk’s site for full details


Find-Me -At PowerGUI.org

PowerGUI Challenge 2010

Kirk Munro, PowerShell MVP, has announced this year’s PowerGUI PowerPack contest. Create a PowerPack or Add-On for PowerGUI and you’ll be in with a chance of a prize if you are deemed to be one of the winners. The prizes are high value Amazon.com vouchers, however both Alan Renouf and I will testify to the fact that winning can give your profile and IT career a real boost!

So I’d encourage you to enter and believe me you will also learn something too from putting a PowerPack together and feel good for making a community contribution.

Looking forward to seeing what people contribute.

PowerGUI Challenge 2010

Updated Exchange 2003 PowerGUI PowerPack

Since PowerGUI version 1.8 there have been some great enhancements in PowerPack management. So I finally got round to updating the Exchange 2003 PowerPack and publishing it in the new format. One of the best new features is the ability to update the PowerPack from the application – previously you had to manually download the new version, remove the old one then import the updated copy.

Within the PowerPack Management Dialogue Box you can see the current version of your PowerPack:


If you click on the Check for Update button PowerGUI will check for an updated version of the PowerPack whether it be on the PowerGUI website or on a locally availbale file share. If there is a new version then you are prompted to download it and upgrade:


Answer Yes and the updated PowerPack will begin to download:


Once complete you will see it has been updated to the new version:


By default PowerGUI will check for updated PowerPacks everytime you open it:


If you are a PowerPack creator then you can specify the location of your PowerPack. PowerGUI will automatically update the version number for you whenever you save any changes to it:


Its as simple as that!

As an extra bonus I have added a new script node to the PowerPack which examines the event log of an Exchange 2003 server and reports the whitespace in each database for you.


Creating Custom Shortcut Keys In PowerGUI

The PowerGUI script editor for PowerShell has long been my IDE of choice. I regularly use its facility to ‘Copy As HTML’ so that I can copy slices of code into blog posts with nice colour formatting. Yesterday I was thinking it would be nice to have a shortcut key to do this rather than have to navigate the menu each time, so I made a post on the forums asking for a feature request, but Shay pointed out that it was already possible to do this.

If you navigate to Tools, Customize, Keyboard, you will see the below which lists anything you can create a keyboard shortcut for:


It even has a nice search facility so in my case typing in HTML returns what I was looking for:


Now simply Assign the key combination you wish to use for the shortcut, save the changes and off you go. Nice!


Exchange 2003 / WMI / PowerShell article over at http://www.simple-talk.com/

So I got asked to write an article for the http://www.simple-talk.com/ website, a well known online technical journal and community hub around SQL and .NET technologies. They’ve recently been branching out into Exchange as well hence they reason they were looking for some Exchange based articles.

The article I have written for them is based around a presentation I have made around some user groups a few times now, i.e. using PowerShell and WMI to manage Exchange 2003. I really enjoyed the process of transferring the content into a written article and hopefully I may get the opportunity to write some more so please check it out.

You can also take advantage of a free Sybex Best Of Exchange 2007 Server ebook by signing up for their Exchange newsletter.

Twitter PowerPack for PowerGUI

Having had some fun previously putting together some PowerPacks for PowerGUI, I had an idea that it would be quite a good tool to use with Twitter. One thing I found annoying with the web interface for Twitter was that it was difficult to see a full list for who you were following and who was following you – you could only see 20 people per page. After Steve Murawski put together his list of Powershell Twitterers at the Mind of Root website I started playing around with some of the ways you could use Powershell to access Twitter data.

Not long afterwards James O’Neill published some PowerShell Twitter functions on his blog which pretty much covered everthing I was looking to cover. If you are a Twitter and PowerShell user I seriously urge you to check these out because they are a really cool way to mess around with some of the data you can get from Twitter. The data is available in XML format, which with PowerShell is very straightforward to handle. The below example shows the Get-TwitterFriend function (I have tweaked James’ code slightly so that it returns all the people you follow, not just the first page of 100) . Essentially you supply some credentials, go get the XML page from the Twitter website, convert it into an XML object and access elements of the XML document since we can get to properties of the XML object.

Function Get-TwitterFriend {
 param ($username, $password, $ID)
 if ($WebClient -eq $null) {$Global:WebClient=new-object System.Net.WebClient  }
 $WebClient.Credentials = (New-Object System.Net.NetworkCredential -argumentList $username, $password)

 $nbrofpeople = 0
 $Friends = @()
 if ($ID) {$URL="http://twitter.com/statuses/friends/$ID.xml?page="}
 else     {$URL="http://twitter.com/statuses/friends.xml?page="}
 do {  $Friends += (([xml]($WebClient.DownloadString($url+($nbrofpeople/100 +1)))).users.user   )
                     # Returns the  user's friends, with current status inline, in the order they were added as friends. 
                     # If ID is specified, returns another user's friends
                     #id:    Optional.  The ID or screen name of the user for whom to request a list of friends.

    $nbrofpeople += 100
    } while ($Friends.count -eq $nbrofpeople)

The XML from Twitter for a user looks like this.

<location>St. Louis</location>

IT Swiss army knife. Lots of powershell right now and VBScript always.

<created_at>Wed May 07 20:31:13 +0000 2008</created_at>
<time_zone>Central Time (US & Canada)</time_zone>


<created_at>Mon Apr 27 20:47:23 +0000 2009</created_at>

You did sort of ask for it. RT @cshanklin: I desperately need a retweet filter.
<source><a href=”http://twitterfall.com”>Twitterfall</a></source>

So to access some of these properties we could do something like this:

Get-TwitterFriend $userName $password | Select-Object name,screen_Name,url,id 

Rather than try re-inventing the wheel and consequently saving myself a bunch of time for the PowerPack, I took these pre-made functions and plugged them into PowerGUI. The results for the initial release are the below:


So if you run the above Get-TwitterFriend function in the PowerPack you get a nice grid view of the people you follow and can easily sort them into alphabetical order by clicking on the Name column.


One of my favourite things is the ability to search Twitter for a particular subject and return the Top 20 people who have posted about that subject recently – this is great if you are looking to check out a particular community to find who might be good people to follow. For instance if you wanted to check out who’s talking about PowerShell on Twitter you would get some results like the below:


Another thing you may find useful in the pack is to check out some of the lists of people published on websites who are known to talk about topics on Twitter, so far I have included the list of PowerShell Twitterers over at the Mind of Root website and Alan Renouf’s list of people who talk about VMWare. I’ve included an action in the PowerPack which once you have pulled down the link and either selected some or all of the people from the list allows you to add them to the list of people you follow on Twitter.


There’s other stuff in the PowerPack, I encourage you to go check it out; give me any feedback, particularly stuff you might like to see added and also check out James’ PowerShell Twitter functions on their own.

Hope you find it useful.

PowerGUI webcast – Exchange 2003 Powerpack demo

I was recently invited to record a webcast by the Product Manager at Quest for PowerGUI, Darin Pendergraft, demoing the Exchange 2003 Powerpack I made for PowerGUI.

They came up with the idea to make some videos / webcasts giving some community members the opportunity to show what PowerGUI can do. A lot of people primarily use it only as a script editor, but the management console side of things is brilliant once you get into it – hopefully these examples will help inspire more people to make some powerpacks.

I had a lot of fun recording the interview, it was funny to be on the other end of the questions for once, normally I’m asking them for the Get-Scripting podcast.

It runs for about 15 – 20 mins, I hope you enjoy it.

Take your own advice Jonathan!

During this last year I’ve done quite a few presentations about Powershell and quite often as part of the demo I have included PowerGUI since I find it a great way to reel people in who aren’t quite yet ready to make a jump the whole way to command line scripting.

One of the topics I usually talk about around this is how I (like most people seem to) initially used the PowerGUI script editor for writing my scripts, but didn’t really get what the PowerGUI console was all about. I couldn’t quite get my head around why you would want a

GUI console for a command shell to manage a GUI OS or product,

it didn’t seem to make much sense to me.

Luckily, we were very fortunate back in May to head over to Quest in the UK with the Powershell User Group for an evening’s event. I decided I’d better figure out what the PowerGUI console was for before attending so watched some of the videos on the PowerGUI site to give myself a better idea.

Doing that and seeing Dmitry’s presentation in the night made things finally click. You could use it to make custom management consoles for your own use or even better to give to a colleague or share with the community. That’s where the idea for the Exchange 2003 PowerPack was born and the Get-Scripting podcast was born almost by accident that night too, but those are stories for another day. 🙂

Anyway, back to the presenting. I often show PowerGUI and explain how you can use it to make custom management consoles to give to colleagues.

Recently I have been working out my notice period before heading to a new job and one of the things I have done during that time is create a bunch of scripts for the regular admin tasks I or others carry out (particularly with AD) which I never got round to writing for myself or them and to save whoever took on my role or parts of it a load of hassle.

For instance I finally got around to creating a script for de-provisioning users which should really help to improve the previous process which was in place. It was based on my good friend Jonathan Noble’s blog post about setting logon hours for an account rather than disabling it so that the email doesn’t bounce. Thanks Jon!

Of course some of these scripts were to be handed over to the helpdesk. Now without being patronising (because we have some very smart people on our helpdesk) it can be quite a jump for a helpdesk person to read through all the documentation I wrote for each script and start running those scripts from the command shell and seeing their results in a blue on black window.

So the cogs started whirring away in the old brain whilst I tried to think of a better way I could deliver these scripts for the helpdesk so they could get up and running with them much quicker and easier without having to read through all the boring documentation first and have a better experience when running them, i.e. don’t put them off using the scripts once I’m not there anymore to help them.

Finally it clicked. Why didn’t I take my own advice I’d been giving out all year about making management consoles for your colleagues and go and do it myself! So the AD Admin Powerpack was born, I packaged up my scripts into this PowerPack, installed PowerGUI for them and instantly the scripts were far more useable.

No need to read all of my boring documentation beforehand since its pretty obvious what clicking on script nodes such as ‘Find Expired AD users’ or ‘How many users in Active Directory?’ will do.

Effective, very simple solutions which save people time, make them more efficient and its makes me feel good to leave something useful like that behind for them to use. Thank you PowerGUI!

Of course the girls on the helpdesk love the train icon so it was an even easier win with them.