Home > Commands A-M > Commands M

MORE


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

Displays one screen of output at a time.

The MORE command reads standard input from a pipe or redirected file and displays one screen of information at a time. This command is commonly used to view long files.


Syntax

MORE /?

MORE [/E [/C] [/P] [/S] [/Tn] [+n]] [drive:][path]filename(s)

MORE [/E [/C] [/P] [/S] [/Tn] [+n]] [<] [drive:][path]filename

command-name | MORE [/E [/C] [/P] [/S] [/Tn] [+n]]


Parameters
< (v7.00 Win95 NT3.1)
Previous versions ONLY acted accepted input as a STDIN filter via redirection, now the file can be a parameter.
command-name (v2.0 Win95 NT3.1)
Specifies the command that supplies data you want to display.
drive: ( path filename v2.0 Win95 NT3.1)
Specifies the location and name of a file that supplies data you want to display.
The file to be displayed. (if more than one separate with spaces).
+n (NT3.1)
Start displaying the first file at line n.

Switches
/? (NTXP)
Displays help.
/C (NT3.1)
Clear screen before displaying page.
/E (NT3.1)
Enable extended features.
/P (NT3.1)
Expand FormFeed characters.
/S (NT3.1)
Squeeze multiple blank lines into a single line.
/Tn (NT3.1)
Expand tabs to n spaces (default 8).

Related

For information about displaying the contents of a directory, see the DIR command.
For information about displaying the contents of a file, see the TYPE command.
ECHO - display variables.
Equivalent Linux BASH commands:
more - Display output one screen at a time.
less - Display output one screen at a time.


Notes
Sources of data

When using the redirection character (<), you must specify a filename as the source. When using the pipe (|), you can use such commands as DIR, SORT, and TYPE. Before using a pipe for redirection, you should set the %TEMP% environment variable in your AUTOEXEC.BAT file.


%MORE% environment variable

You can create an environment variable called %MORE% and use this to supply any of the switches.


% complete

When MORE is used without any redirection symbols it will display the % complete e.g.

    MORE /E myfile.txt
    --More (17%) --

Extended features keystrokes

If extended features are enabled, (/E) the keystrokes can be used at the -- More -- prompt:


Examples

Suppose you have a long file named CLIENTS.NEW that you want to view on your screen. Either of the two commands redirects the file through the MORE command to begin displaying the contents of the file:

    MORE < CLIENTS.NEW

or

    TYPE CLIENTS.NEW | MORE

The MORE command displays the first screen of information from CLIENTS.NEW and then prompts you with:

    -- More --

You can then press any key to see the next screen of information.


Errorlevels

none.


Availability
External
DOS
v2.0 v2.01 v2.05 v2.10 v2.11 v2.11R v2.12 v2.2 v2.25 v3.0 v3.20 v3.05 v3.1 v3.21 v3.25 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
NT3.1 NT3.5 NT3.51 NT4 NT2000 NTXP NT2003

Last Updated: 2006/12/01
Direct corrections or suggestions to: Rick Lively