PRB: setlocale(LC_ALL, ".OCP") Returns NULL for Some Locales on US Windows NT 4.0 (230138)
The information in this article applies to:
- Microsoft Windows NT Server 4.0
- Microsoft Windows NT Workstation 4.0
This article was previously published under Q230138 IMPORTANT: This article contains information about modifying the registry. Before you
modify the registry, make sure to back it up and make sure that you understand how to restore
the registry if a problem occurs. For information about how to back up, restore, and edit the
registry, click the following article number to view the article in the Microsoft Knowledge Base:
256986 Description of the Microsoft Windows Registry
SYMPTOMS
On Windows NT 4.0, if the locale is similar to one of the following, setlocale(LC_ALL,".OCP") may return NULL:
- Russian_Russia
- Serbian (Latin)_Serbia
- Slovak_Slovakia
- Turkish_Turkey
- Ukrainian_Ukraine
CAUSE
This is by design. Windows NT 4.0 no longer copies various OEM code pages to the system at installation time. For US Windows NT, only OEM code pages 437 and 850 are installed at setup time. The locales listed in the "Summary" section all require OEM code pages other than 437 and 850, and therefore setlocale(LC_ALL, ".OCP") returns NULL.
RESOLUTIONWARNING: If you use Registry Editor incorrectly, you may cause serious problems that may
require you to reinstall your operating system. Microsoft cannot guarantee that you can solve
problems that result from using Registry Editor incorrectly. Use Registry Editor at your own
risk.
To install the additional OEM code pages, copy them from the Windows NT setup CD to the Windows NT System32 directory, then update the registry:
HKEY_LOCAL_MACHINE\SYSTEM\currentcontrolset\control\NLS\codepage
The locale listed in the "Summary" section require different code pages:
- Russian_Russia.866
- Serbian (Latin)_Serbia.852
- Slovak_Slovakia.852
- Ukrainian_Ukraine.866
Modification Type: | Minor | Last Reviewed: | 2/11/2004 |
---|
Keywords: | kbDSXGlobal2003Swept kbCRT kbLocalization kbNLS kbprb KB230138 |
---|
|