International settings during autopilot

Alessandro Zola 101 Reputation points
2021-02-09T10:45:36.537+00:00

Hi all,
I need to modify the international settings like decimal, days ecc...during autopilot process...
I create a powershell script like this
Set-ItemProperty -Path "HKCU:\Control Panel\International" -Name Locale -Value 00000410
Set-ItemProperty -Path "HKCU:\Control Panel\International" -Name LocaleName -Value it-IT
Set-ItemProperty -Path "HKCU:\Control Panel\International" -Name sCurrency -Value €
Set-ItemProperty -Path "HKCU:\Control Panel\International" -Name sdecimal -Value "."
Set-ItemProperty -Path "HKCU:\Control Panel\International" -Name sLanguage -Value ITA
Set-ItemProperty -Path "HKCU:\Control Panel\International" -Name sLongDate -Value "dddd d MMMM yyyy"
Set-ItemProperty -Path "HKCU:\Control Panel\International" -Name sShortDate -Value "dd/MM/yyyy"
Set-ItemProperty -Path "HKCU:\Control Panel\International" -Name sTimeFormat -Value "HH:mm:ss"
Set-ItemProperty -Path "HKCU:\Control Panel\International" -Name sShortTime -Value "HH:mm"
Set-ItemProperty -Path "HKCU:\Control Panel\International" -Name iCountry -Value 39
Set-ItemProperty -Path "HKCU:\Control Panel\International" -Name iCurrency -Value 3
Set-ItemProperty -Path "HKCU:\Control Panel\International" -Name idate -Value 1
Set-ItemProperty -Path "HKCU:\Control Panel\International" -Name iFirstDayOfWeek -Value 0
Set-ItemProperty -Path "HKCU:\Control Panel\International" -Name iFirstDayOfYear -Value 2
Set-ItemProperty -Path "HKCU:\Control Panel\International" -Name iMeasure -Value 0
Set-ItemProperty -Path "HKCU:\Control Panel\International" -Name iNegCurr -Value 8
Set-ItemProperty -Path "HKCU:\Control Panel\International" -Name iPaperSize -Value 9
Set-ItemProperty -Path "HKCU:\Control Panel\International" -Name iTime -Value 1
Set-ItemProperty -Path "HKCU:\Control Panel\International" -Name iTLZero -Value 1

And created win32 application
Even if seems to deploy the script and the detection method works the registry keys are not changed..
Any idea ora other methor to achieve the goal?
Thanks

Microsoft Security | Windows Autopilot
Microsoft Security | Intune | Application management
{count} votes

3 answers

Sort by: Most helpful
  1. Alessandro Zola 101 Reputation points
    2021-02-10T08:27:36.693+00:00

    Hi if I run the powershell manually it works. i cannot try the app with intune because I'm in co.management and I have the application workload still on sccm.

    My win32 app installation script is
    "C:\Windows\System32\WindowsPowerShell\V1.0\PowerShell.exe" -NoLogo -NonInteractive -NoProfile -ExecutionPolicy Bypass -File regional.ps1

    the report says that is installed ant the check is on one of the registry key I change...
    66247-image.png

    0 comments No comments

  2. Crystal-MSFT 53,991 Reputation points Microsoft External Staff
    2021-02-11T05:18:34.447+00:00

    @Alessandro Zola , Thanks for the reply. From the phenomenon we get, I wonder this can be with the account which we run the script. based on my experience, for the registry key under HKCU, it can only change the value in current user. For other user, it will not change. Given the situation, please check which account we use to run the Win32 app, under User or System. Please change to User to see if the result will be different.
    66817-image.png

    Hope it can help.


    If the response is helpful, please click "Accept Answer" and upvote it.
    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    0 comments No comments

  3. Alessandro Zola 101 Reputation points
    2021-02-11T07:52:07.897+00:00

    I cannot change is grayed out....


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.