Article ID: 211147 - Last Review: February 12, 2007 - Revision: 3.1 INFO: Internet Explorer Script Prompts and MBCS/UnicodeThis article was previously published under Q211147 SUMMARY
On systems running English language versions of Windows 95, Windows 98, and Windows NT, certain Microsoft Visual Basic Script (VB Script) and Document Object Model (DOM) procedures for displaying feedback to the user cannot handle the display and input of text in multibyte character systems, such as Japanese and Chinese. These procedures are:
MORE INFORMATION
Languages using non-Latin scripts are represented on Windows systems in one of two forms: Unicode or non-Unicode (MBCS). Unicode is a single character set representing most of the world's languages; it maps each character in each written language system to a unique number. MBCS standards, such as Shift-JIS for Japanese or Big5 for Chinese, define such mappings for a single language (with ASCII usually included as well for compatibility). Both Windows NT and Windows 9x platforms support the display of Unicode text within a window using the ExtTextOutW() function. Internet Explorer uses this function for all its language display, converting MBCS character encodings to Unicode using the MLang component. Additionally, Internet Explorer hooks into the Input Method Editor (IME), allowing input of non-Latin script into browser forms. The functions alert(), prompt(), confirm(), MsgBox, and InputBox all ultimately call Win32 functions such as MessageBox(), which can only display text for the default system locale. (While functions such as MessageBoxEx() and MessageBoxIndirect() do allow you to specify a language ID, most non-Western European languages, such as Japanese, are not installed by default on English Windows NT.) Also, because these functions were not designed to interoperate with the Input Method Editor, it is impossible to type non-Latin script into them on English systems. If you want to create truly global applications, you must leverage Internet Explorer's multilingual capabilities and replace calls to the procedures named earlier with code that opens HTML dialogs using either showModalDialog() or showModelessDialog(). For an example, see the following Microsoft Knowledge Base article: 244397
(http://support.microsoft.com/kb/244397/EN-US/
)
BUG: JScript Calling Window.prompt Cannot Handle DBCS Correctly
This problem does not affect localized versions of Windows systems, as long as the specified language is used. In other words, Japanese text displays fine in an alert box on systems running Japanese Windows, and the IME activates for prompt dialogs. Additionally, users of Windows 2000 Multilingual User Interface Edition (MUI) can bypass this problem by installing support for the appropriate language.
REFERENCESFor more information about developing Web-based solutions for Microsoft Internet Explorer, visit the following Microsoft Web sites: http://msdn.microsoft.com/ie/
(http://msdn.microsoft.com/ie/)
For additional information, click the article number below
to view the article in the Microsoft Knowledge Base:
http://support.microsoft.com/iep (http://support.microsoft.com/iep) 125671
(http://support.microsoft.com/kb/125671/EN-US/
)
Unicode Functions Supported by Windows 95
To download language packs and Input Method Editors for a variety of non-English languages, see the following Microsoft Web site:
Windows Update
(http://www.windowsupdate.com)
APPLIES TO
| Article Translations
|
Back to the top
