Share This Post

Check if PowerShell installed and version

To check if PowerShell is installed use:
HKLM\Software\Microsoft\PowerShell\1 Install ( = 1 )
To check if RC2 or RTM is installed use:
HKLM\Software\Microsoft\PowerShell\1 PID (=89393-100-0001260-00301) — For RC2
HKLM\Software\Microsoft\PowerShell\1 PID (=89393-100-0001260-04309) — For RTM

Also you could do the following

PS C:\Myworkplace\PS> get-host

Name : ConsoleHost
Version : 1.0.0.0
InstanceId : 2a52c07a-b708-430b-952a-af9f73431b46
UI : System.Management.Automation.Internal.Host.InternalHostUserInterface
CurrentCulture : en-US
CurrentUICulture : en-US
PrivateData : Microsoft.PowerShell.ConsoleHost+ConsoleColorProxy

PS C:\Myworkplace\PS> $host.version

Major Minor Build Revision
—– —– —– ——–
1 0 0 0

But the above will only give you the host version not the file version and for most people that’s good enough.

In case you are curious, you could do the following

PS C:\Myworkplace\PS> (gcm "$PSHome\PowerShell.exe").FileVersionInfo.ProductVersion
6.0.5429.0

Share This Post

Ying Li obtained a Master degree of Medicine in China and worked in the medical field before he came to the states in 1996. He made the career switch from troubleshooting people to troubleshooting computers after he came to the states. Not entirely a surprise there, if you know that his second preference for college is Mathematics. Ying is two times Admin Framework MVP awardee (2007-2008).His previous employment experience in the US includes UUNET, MCI WorldCom. MMC (Marsh & McLennan Companies), Merrill Lynch. He is currently employed by Related Companies as a Senior Infrastructure Engineer. He is proficient in virtually all Microsoft products (Office/Back office). His craving for efficiency naturally leads him to scripting, automation and before you know it, PowerShell! He is currently a MCSE (NT4, 2000, 2003) and MCITP Server Administrator. Ying enjoys wines and love to travel. His non work related passion is to advocate Health Living!

Leave a Reply