Welcome guest. Before posting on our computer help forum, you must register. Click here it's easy and free.

Author Topic: prompt  (Read 4465 times)

0 Members and 1 Guest are viewing this topic.

bernt_nr1

  • Guest
prompt
« on: July 29, 2004, 04:03:23 PM »
what is prompt  ???  :-[

is it a abbrevi'ation  ???

robertmillar

  • Guest
Re: prompt
« Reply #1 on: July 30, 2004, 05:31:13 AM »
It is the command line in DOS

MalikTous

  • Guest
Re: prompt
« Reply #2 on: July 31, 2004, 02:39:32 PM »
The environment variable 'prompt' is the 'label' at the front of the DOS command line.

prompt $p$g
c:\windows>

prompt Press any key to format C drive
Press any key to format C drive
(This was a popular joke back in the DOS days. Annoying, but basically harmless. No actual format would be done.)

prompt Win4.1 $p$g
Win4.1 c:\windows>

A prompt is any character group indicating the system is ready to accept a DOS command. Some attempts by DOS virii to install 'ANSI bombs' as prompts caused a little consternation back a decade ago, but most of that business is easily prevented with a virus scanning app.
« Last Edit: July 31, 2004, 02:41:19 PM by MalikTous »

johnwill

  • Guest
Re: prompt
« Reply #3 on: August 01, 2004, 02:47:39 PM »
If you type:

PROMPT /?

You'll get decent help:

Changes the cmd.exe command prompt.

PROMPT [text]

 text    Specifies a new command prompt.

Prompt can be made up of normal characters and the following special codes:

 $A   & (Ampersand)
 $B   | (pipe)
 $C   ( (Left parenthesis)
 $D   Current date
 $E   Escape code (ASCII code 27)
 $F   ) (Right parenthesis)
 $G   > (greater-than sign)
 $H   Backspace (erases previous character)
 $L   < (less-than sign)
 $N   Current drive
 $P   Current drive and path
 $Q   = (equal sign)
 $S     (space)
 $T   Current time
 $V   Windows 2000 version number
 $_   Carriage return and linefeed
 $$   $ (dollar sign)

If Command Extensions are enabled the PROMPT command supports
the following additional formatting characters:

 $+   zero or more plus sign (+) characters depending upon the
      depth of the PUSHD directory stack, one character for each
      level pushed.

 $M   Displays the remote name associated with the current drive
      letter or the empty string if current drive is not a network
      drive.