Was this page helpful?
Additional feedback?
1500 characters remaining
Export (0) Print
Expand All


Updated: January 21, 2005

Applies To: Windows Server 2003, Windows Server 2003 R2, Windows Server 2003 with SP1, Windows Server 2003 with SP2


Suspends the processing of a batch program and displays a message that prompts the user to press any key to continue.



Displays help at the command prompt.

  • When you run the prompt command, the following message appears:

    Press any key to continue . . .            
  • If you press CTRL+C to stop a batch program, the following message appears:

    Terminate batch job (Y/N)?            
    If you press Y (for yes) in response to this message, the batch program ends and control returns to the operating system. Therefore, you can insert the pause command before a section of the batch file that you might not want to process. While pause suspends processing of the batch program, you can press CTRL+C and then press Y to stop the batch program.


To create a batch program that prompts the user to change disks in one of the drives, type:

@echo off 
copy a:*.* 
echo Put a new disk into drive A 
goto begin        

In this example, all the files on the disk in drive A are copied to the current directory. After the message prompts you to put a new disk in drive A, the pause command suspends processing so that you can change disks and then press any key to resume processing. This particular batch program runs in an endless loop. The goto BEGIN command sends the command interpreter to the begin label of the batch file. To stop this batch program, press CTRL+C and then press Y.

Formatting legend


Format Meaning


Information that the user must supply


Elements that the user must type exactly as shown

Ellipsis (...)

Parameter that can be repeated several times in a command line

Between brackets ([])

Optional items

Between braces ({}); choices separated by pipe (|). Example: {even|odd}

Set of choices from which the user must choose only one

Courier font

Code or program output

See Also

Was this page helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

© 2015 Microsoft