PSADT not correctly retrieving OS language

//PSADT not correctly retrieving OS language
PSADT not correctly retrieving OS language 2017-12-21T20:49:14+00:00

The Toolkit Forums General PSADT not correctly retrieving OS language

  • Author
    Posts
  • Virgil
    Participant
    Post count: 4
    #2562 |

    PSADT is not correctly retrieving the OS language. It is always returning English when the OS is French.
    The AppDeployToolkitMain.ps1 uses:
    [Globalization.CultureInfo]$culture = Get-Culture
    [string]$currentLanguage = $culture.TwoLetterISOLanguageName.ToUpper()

    If I use local powershell ISE on French machine with the above commands the OS is returned fr-FR.
    But when executing the install PSADT returns:
    [Initialization] :: Current Culture is [en-US] and UI language is [EN]

    Anybody know where get-culture is pulling the OS language from?
    HKCU\Control Panel\Desktop PreferredUILanguages? This entry is not always present

  • Virgil
    Participant
    Post count: 4

    After changing the default language in Region & Language I needed to go to Administrative tab and select Copy Settings and then under “Copy your current settings to” enable “Welcome screen and system accounts”

  • Seán Lillis
    Keymaster
    Post count: 16

    Can you try running Get-UICulture and let me know what result you get? We may need to switch to using that cmdlet in the toolkit to correctly identify the language.

    https://social.technet.microsoft.com/Forums/en-US/56e38348-77c8-4b0c-b03a-9631e1583d9e/different-results-from-getuiculture-and-getculture-in-powershell?forum=w7itprogeneral

    • This reply was modified 4 weeks, 1 day ago by  Seán Lillis.

You must be logged in to reply to this topic.