Technology in terms you understand. Sign up for the Confident Computing newsletter for weekly solutions to make your life easier. Click here and get The Ask Leo! Guide to Staying Safe on the Internet — FREE Edition as my thank you for subscribing!

Tip of the Day: Help and More

Help piped into More

Three tips in one, today, for the Command Prompt.

The Help command

In Windows Command Prompt, type Help followed by the enter key. What you’ll see fly by is a list of nearly 100 different commands that can be used in the Command Prompt.

Some are actual stand-alone programs. For example, the second item on the list is something called “ATTRIB”. That corresponds to the program file C:\Windows\system32\attrib.exe. (Command Prompt commands are case insensitive.)

Some are what are called “built in” commands — you won’t find them anywhere on the machine. An example is the first on the list: “ASSOC”. This command is implemented within the Command Prompt itself.

You can get help on individual commands by typing “Help” followed by the name of the command. You can even type “Help Help”.

The More command

The list output generated by Help is much longer than your Command Prompt window, so much of the output was lost as it scrolled past the top. This is a common problem in command line programs, and there’s a simple solution: the “More” program.

“More” displays input one screen at a time, pausing for a key press after each. This way, you can read the contents of one screen and then press a key (I recommend the space bar) to see the next, and so on.

You can exit the program early by pressing the Q key (or Ctrl-Break, in earlier versions of Windows).

The question, then, is how to get the output of the Help command to be the input for the More command.

Piping

Piping is exactly that: taking the output of one program and providing it as input to another. For example, in Command Prompt, type:

Help | More

where “|” is the vertical bar character, often referred to as the “pipe” character. This instructs the first program to “pipe” its output into the second. Now the list provided by Help will be displayed one screen at a time, controlled by More.

Finally, you can get Help on More.

Help More

Note that there is no pipe character in that command: the word “More” was provided as a parameter to the Help command, asking it to display information about the command “More”.

If that’s longer than your window is tall, you can pipe that output into More so you can see it a screen at a time:

Help More | More

In English, that’s running the Help program, asking for help on “More”, and piping that output through the program “More” so as to display one screen full at a time.

Related Video

4 comments on “Tip of the Day: Help and More”

  1. This is interesting, certainly. I am not nor have I ever been a programmer (well a bit of Basic on a Sinclair Spectrum way back when until I felt it was beyond me), but I do find knowing there is a Help feature here useful to know.

    Reply
  2. I used to use the |more pipe command in older versions of Windows. In more recent versions, the Command Line screen is scrollable and |more piping is not as necessary.

    Reply

Leave a reply:

Before commenting please:

  • Read the article.
  • Comment on the article.
  • No personal information.
  • No spam.

Comments violating those rules will be removed. Comments that don't add value will be removed, including off-topic or content-free comments, or comments that look even a little bit like spam. All comments containing links and certain keywords will be moderated before publication.

I want comments to be valuable for everyone, including those who come later and take the time to read.