Advertisement
easternnl

Get-WindowsUILanguage

Dec 18th, 2015
517
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. Function Get-WindowsUILanguage
  2. {
  3. <#
  4.    .Synopsis
  5.     This function gets the Windows UI language for the current user.
  6.    .Description
  7.     This function gets the Windows UI language for the current user.
  8.    .Example
  9.     Get-WindowsUILanguage
  10.     Returns the UI language in nl-NL, en-US or anyother language  
  11.    .Notes
  12.     NAME:  Get-WindowsUILanguage
  13.     AUTHOR: Erik van Oost
  14.     LASTEDIT: 18/12/2015
  15.     KEYWORDS: Printer Drivers    
  16.    .Link
  17.      Http://blog.eastern.nl
  18.  #Requires -Version 3.0
  19.  #>
  20.  Param([string[]]$name)
  21.  
  22.    
  23.     $language = (Get-ItemProperty "HKCU:\Control Panel\Desktop").PreferredUILanguages
  24.     return $language
  25.  
  26.  }
  27.  
  28.  Get-WindowsUILanguage
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement