Home > Commands A-M > Commands M

MODE (Set Device Code Pages)


Description | Syntax | Parameters | Switches | Related | Notes | Examples | Errorlevels | Availability

Prepares, selects, refreshes, or displays the numbers of the character sets (code pages) for parallel printers or the keyboard and monitor. For an introduction to using character sets, see "Customizing for International Use" in the DOS User's Guide -- or see section 1.2.


Syntax

MODE /?

MODE device CODEPAGE PREP[ARE]=((yyy [...]) [drive:][path]filename)

MODE device CODEPAGE SEL[ECT]=yyy

MODE device CODEPAGE REF[RESH]

MODE device CODEPAGE [/STA[TUS]]


Parameters
CODEPAGE | CP (v3.30 Win95 NT4)
Displays the numbers of the character sets, if any, that are prepared or selected for the specified device. You can abbreviate CODEPAGE as CP.
device (v3.30 Win95 NT4)
Specifies the device for which you want to prepare or select a character set. Valid names for device are:
drive: ( path filename v3.30 Win95)
Specifies the location and name of the code-page-information (.CPI) file that the operating system uses to prepare a character set for the specified device.
PREP[ARE] (v3.30 Win95)
Prepares character sets for the specified device. You must prepare a character set for a device before you can use the character set with that device. After you use the CODEPAGE PREPARE form of the MODE command, use the CODEPAGE SELECT form of MODE to specify the character set you want to use. You can abbreviate PREPARE as PREP.
REF[RESH] (v3.30 Win95)
Reinstates the prepared character sets if they are lost as the result of a hardware problem or other error. You can abbreviate REFRESH as REF.
SEL[ECT] (v3.30 Win95 NT4)
Specifies (selects) which character set to use with the specified device. Before selecting a character set, you must use the CODEPAGE PREPARE form of the MODE command to prepare a character set. You can abbreviate SELECT as SEL.
yyy (v3.30 Win95 NT4)
Specifies the number of the character set to prepare or select. The list shows each character set supported by the EGA.CPI file and its country or language: Additional character sets are supported by the EGA2.CPI and EGA3.CPI files. For more information, see "Customizing for International Use".

Switches
/? (NTXP)
Displays help.
/STA[TUS] (v3.30 Win95 NT4)
Displays the numbers of the current character sets prepared or selected for the specified device. You can abbreviate this switch as /STA. Whether or not you specify the /STATUS switch, typing the MODE command with a device name and the CODEPAGE parameter displays the numbers of the character sets that are prepared or selected for the specified device.

Related

For information about other character-set commands, see the NLSFUNC and CHCP commands.
MODE - Configure Printer.
MODE - Configure Serial Port.
MODE - Display Device Status.
MODE - Redirect Printing.
MODE - Set Display Mode.
MODE - Set Typematic Rate.


Notes
CPI files

The operating system includes three .CPI files: EGA.CPI, EGA2.CPI, and EGA3.CPI. The EGA.CPI is the default CPI file. The EGA2.CPI and EGA3.CPI files provide additional codepages not supported by EGA.CPI. (For more information, see "Customizing for International Use").


Examples

none.


Errorlevels

none.


Availability
External Resident
DOS
v3.30 v3.3A v3.3R v3.3T v3.31 v3.40 v4.0 v4.01 v4.01A v5.0 v5.0A v5.00.02 v5.001A v5.01 v5.02 v6.0 v6.10 v6.2 v6.21 v6.22 v6.23 v7.00 v7.0R1 v7.10 v8.00
Windows
Win95 Win98 WinME
Windows NT
NT4 NT2000 NTXP NT2003