Tag Archives: PowerShell 5.0

PowerShell 5.0 RTM available for download

PowerShell 5.0, part of the Windows Management Framework 5.0 (WMF 5.0), is now released and available in the Microsoft Download Center.

WMF5Released

WMF 5.0 is currently available as a separate download for the following Windows versions:

Operating System Service Pack Prerequisites
Windows Server 2012 R2 .NET Framework 4.5 or above
Windows Server 2012 .NET Framework 4.5 or above
Windows Server 2008 R2 SP1 WMF 4.0 is installed and .NET Framework 4.5 or above
Windows 8.1
Windows 7 SP1 WMF 4.0 is installed and .NET Framework 4.5 or above

Currently WMF 5.0 RTM can be installed on older Windows clients, Windows 7 and Windows 8.1,  the updates can be downloaded. On Windows 10 WMF 5.0 is not available as an additional download as Windows Update can be used to update the Windows Management Framework.

Before installing WMF 5.0 on your system, please make sure that you read the released notes as there are currently known incompatibilities with the following products:

  • Microsoft Exchange Server 2013
  • Microsoft Exchange Server 2010 SP3
  • Microsoft SharePoint Server 2013
  • Microsoft SharePoint Server 2010
  • System Center 2012 Virtual Machine Manager

For more information please refer to the Windows Management Framework (WMF) 5.0 RTM Release Notes Overview on MSDN.

For more information on WMF 5.0 and the links in this article please refer to the links below:

Links in this Article
Windows Management Framework 5.0 Download
Windows Management Framework (WMF) 5.0 RTM Release Notes Overview
Known Incompatibilities
PowerShell Team – Windows Management Framework (WMF) 5.0 RTM is now available
Windows Management Framework (WMF) 5.0 currently removed from Download Center

Video Presentation with Experts Live TV available online on Channel9 and YouTube

Last week I met up with Bert Wolters for a video presentation/interview. Bert has been recording a series of sessions on the latest and greatest functionality in Windows 10 and in this episode I discuss some of the new functionalities in PowerShell 5.0 in combination with Windows 10. The video has been recorded in Dutch, so unfortunately it will a bit hard to follow for the English speaking community.

In the video I showcase the following features:

  • Better Multiline support for the PowerShell console
  • Colored console for cmdlets, parameters and arguments
  • PowerShell cmdlets for Windows Defender
  • PowerShell debugging in the ISE using <CTRL> + B
  • DuPSUG, Dutch PowerShell User Group

Alternatively the video is also available on Microsoft’s Channel9:

For more information or the direct link of the video in this article please refer to the links below. Feel free to leave a comment either here or in the YouTube comment section.

Links in the article
Channel9 – Experts Live TV – 10 weken Windows 10 – Aflevering 9 – Powershell 5
Channel9 – Windows 10 in 10 Minuten
YouTube – Experts Live TV – 10 weken Windows 10 – Aflevering 9 – Powershell 5
DuPSUG.com, Dutch PowerShell User Group

Clear-RecycleBin New PowerShell 5.0 cmdlet, available in Windows 10

In PowerShell 5.0 a new cmdlet has been introduced that provides the ability to clear the Recycle Bin programmatically. It supports the following four parameters:

  1. DriveLetter
  2. Force
  3. WhatIf
  4. Confirm

Unfortunately there is no Get-RecycleBin cmdlet, for this purpose I have written a short function that enumerates the contents of Recycle Bin for the current user:

1
2
3
4
Function Get-RecycleBin {
    (New-Object -ComObject Shell.Application).NameSpace(0x0a).Items() |
	Select-Object Name,Size,Path
}

Get-RecycleBin

By verifying this output we can now determine if we would like to Clear the Recycle Bin or if some files that are stored there should be recovered before deleting all files. The following command will delete all files from the Recycle Bin for all drive letters:

1
Clear-RecycleBin

Clear-RecycleBin

The default mode of operation of this cmdlet is to ask for confirmation before deleting all files. This is similar behavior to right clicking the icon of Recycle Bin and clicking ‘Empty Recycle Bin’. To delete the files without confirmation the following code can be used:

1
Clear-RecycleBin -Force

Alternatively the Confirm parameter can also be explicitly set to $false:

1
Clear-RecycleBin -Confirm:$false

Unfortunately there is no online help available for this cmdlet, so for more information about this cmdlet please refer to the built-in help in PowerShell:

1
Get-Help Clear-RecycleBin -ShowWindow

For more information or the direct download links of these scripts please refer to the links below. Feel free to leave a comment either here or in the TechNet Script Library.

TechNet Script Gallery
My entries in TechNet Script Gallery
Get-RecycleBin – shows the contents of the Recycle Bin

Windows 10 Build 10159 Released – Start of Windows 10 Blog Series

W10B10159Microsoft announced the release of the latest build of Windows 10, Build 10159: Whoa! Another PC build!, it is available for download if you set the Windows Update settings to Fast. By setting it on this mode, Windows Update will automatically download the latest build when it becomes available.

To get the most recent preview builds installed on your Windows 10 Technical Preview build navigate to:

  • Advanced Update Settings
  • Choose how preview builds are installed
  • Set Pull-down menu to ‘Fast’

W10-FastRing

As today it is the first of July I decided to create two new categories on my blog, Windows 10 and Windows Server 2016. At the 29th of July Windows 10 will be officially released so I will use the coming weeks to highlight some of the unique, redesigned functionalities of both the OS as well as the automation features that are available to us. The will be a heavy emphasis on the new and updated functionality of PowerShell 5.0.

As an extra I have attached the download link of the, 4K Hero Wallpaper, the new default wallpaper that is included in the 10159 build. The links are available here:

Windows 10 Build 10159 Released
Whoa! Another PC build!
4K Hero Windows 10 Wallpaper

PowerShell DSC Resource Kit Wave 5 has been released

Today the PowerShell team announced that the latest iteration of their Desired State Configuration Resource Kit has been released. This is an experimental resource that is intended for lab and testing purposes. The latest version is available in the Technet Script Gallery:

DSC Resource Kit (All Modules)

Depending on which modules you will be using this resource kit either requires Server 2012 R2/Windows 8.1 with PowerShell 4.0. The xJEA module requires installation of the Windows Management Framework 5.0 Preview.

The original announcement by the PowerShell Team is available here:
PowerShell DSC Resource Kit Wave 5 Arrives

Windows Management Framework 5.0 Preview May 2014 Released

It has been a great week at Microsoft TechEd North America, many sessions including PowerShell code. It is a great time to be involved with PowerShell as Microsoft definitely has a very strong focus on this product. As announced by Jeffrey Snover the new preview version has become available this week. It is available for download here:

Windows Management Framework 5.0 Preview May 2014

Most notable new features in this release are the inclusion of PowerShellGet and the improvements on DSC, many of which were already showcased at TechEd this week. Two important things to note before you get started with PowerShell 5 and Windows Management Framework 5.0 are as follows:

  • First uninstall any previous versions of the WMF preview
  • Windows Management Framework 5.0 will only install on Windows 8.1 or Server 2012R2

The PowerShell Team has written excellent blog posts on the preview versions they are available here:

Windows Management Framework 5.0 Preview May 2014 is now available
Windows Management Framework V5 Preview