Sub ChangeSystemLocaleToPersian()
Dim regPath As String
Dim shell As Object

' مسیر رجیستری برای تغییر locale
regPath = "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Contr ol\Nls\Locale"

' ایجاد شیء Shell
Set shell = CreateObject("WScript.Shell")

' تغییر مقدار Locale به 00000429 (فارسی)
shell.RegWrite regPath & "Locale", "00000429", "REG_SZ"

' تغییر مقادیر ACP، MACCP و OEMCP به 1256 (کد صفحه‌ی فارسی)
regPath = "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Contr ol\Nls\CodePage"
shell.RegWrite regPath & "ACP", "1256", "REG_SZ"
shell.RegWrite regPath & "MACCP", "1256", "REG_SZ"
shell.RegWrite regPath & "OEMCP", "1256", "REG_SZ"

MsgBox "Current System Locale has been changed to Persian (فارسی). Please restart your computer."
End Sub