To become familiar with the Mail Utility, use the twelve MAIL
commands discussed in this section. These twelve commands will
enable you to move around within the Mail Utility. For more
detailed information about the Mail Utility, see the VAX/VMS
Utilities Reference Volume.
These are the twelve MAIL commands discussed in this section:
SEND DIRECTORY EXTRACT
READ[/NEW] DELETE PRINT
FORWARD MOVE HELP
REPLY SELECT EXIT
The first command to try is the SEND command. Try sending a message
to yourself. Enter the SEND command and press RETURN. Enter your
own user name at the prompt and press RETURN. Enter a subject
when prompted and press RETURN again. The following example shows
how to use the SEND command:
MAIL> SEND
To: PIERCE
Subj: Sailing
Enter your message below. Press CTRL/Z when complete, or CTRL/C to quit:
When you finish entering the text of your message, press CTRL/Z.
Because you are sending the message to yourself, MAIL will signal
that you have just received a new message by displaying the
following message:
New mail on node FLAXEN from PIERCE
MAIL>
Now, you are ready to use the READ command. To read the message you
just sent to yourself, enter the READ command with the /NEW
qualifier and press RETURN.
MAIL> READ/NEW
You must specify the /NEW qualifier with the READ command when you
want to read new mail that arrives while you are in the Mail
Utility. When you are not in the Mail Utility and you receive new
mail, then invoke MAIL to read the new message, you can enter the
READ command without the /NEW qualifier. Or, if you wish to read
mail that you have already read, you can also enter the READ command
without the /NEW qualifier.
You can forward a copy of a mail message to another user by entering
the FORWARD command. MAIL will prompt you for the name of the user
to receive the message. Try forwarding a copy of the message you
just received back to yourself. Enter your own user name and press
RETURN. Supply a subject when prompted and press RETURN. MAIL will
signal that you have just received a new message. Enter the
READ/NEW command to read the forwarded message.
When you receive a message and want to respond to it, enter the
REPLY command and press RETURN. MAIL will display the header
information as follows:
MAIL> REPLY
To: FLAXEN::PIERCE
Subject: Re:Using the REPLY command
Enter your message below. Press CTRL/Z when complete, or CTRL/C to quit:
When you finish typing your response, press CTRL/Z. Again, MAIL
will signal that you have just received a new message. To read the
message, enter the READ/NEW command.
When you want to see a list of all the mail messages you have
collected, enter the DIRECTORY command and press RETURN. MAIL will
display a list like the following:
# From Date Subject
1 FORBES 1-JUN-1985 How to Write a Memo
2 STELLA::BERT 2-JUN-1985 Using the Printer
3 FROST::BASTIEN 4-JUN-1985 Chicken Kiev
When you want to remove a message, use the DELETE command. You can
either enter the DELETE command while you are reading the message or
you can enter the DELETE command followed by the number of the
message you want to remove. To remove the second message in the
list, enter the following command line:
MAIL> DELETE 2
If you enter the DIRECTORY command after you have deleted a message
(or messages), you will see the messages marked for deletion, as the
following example shows:
# From Date Subject
1 FORBES 1-JUN-1985 How to Write a Memo
2 (Deleted)
3 FROST::BASTIEN 4-JUN-1985 Chicken Kiev
When you exit from MAIL, the messages marked for deletion will
disappear.
The Mail Utility allows you to organize your messages by moving them
into folders. To move a message to a folder, enter the MOVE command
(while you are reading the message) and press RETURN. MAIL will
prompt you for a folder name. Type any name, for example, REVIEWS
or JOKES or STATUS_REPORTS. MAIL will also prompt you for a file
name. You can specify the default mail file by pressing RETURN. A
sample session demonstrating the MOVE command follows. (The folder
name is WINNERS and the default mail file is specified.) If the
folder you name does not exist, MAIL will ask you if you want to
create it.
MAIL> 2
MAIL> MOVE
_Folder: WINNERS
_File: <RET>
Folder WINNERS does not exist.
Do you want to create it (Y/N, default is N)? Y
%MAIL-I-NEWFOLDER, folder WINNERS created
Once you have created folders, you will want to move between them.
To move from one folder to another, use the SELECT command. If you
want to move to the WINNERS folder, enter the following command
line. (MAIL displays a message indicating the number of messages in
the folder.)
MAIL> SELECT WINNERS
%MAIL-I-SELECTED, 1 message selected
To move to a folder named JOKES, enter the following command line:
MAIL> SELECT JOKES
%MAIL-I-SELECTED, 32 messages selected
You can enter the DIRECTORY command to see a list of the messages in
the folder you just selected.
When you want to move a mail message from your mail file to a
sequential file that you can access from the DCL command level, use
the EXTRACT command. Enter the EXTRACT command (while you are
reading the message) and press RETURN. MAIL will prompt you for the
name of a file. Then, when you exit from MAIL, the file will be
listed in your main directory. The following example shows how to
use the EXTRACT command to move a mail message to a file named
GAMES.DAT.
MAIL> EXTRACT
_File: GAMES.DAT
%MAIL-I-CREATED, DISK:[BERGMAN]GAMES.DAT;1 created
MAIL>
To make a hard copy of a mail message, enter the PRINT command while
you are reading the message and press RETURN. (When you exit from
MAIL, the message will enter the print queue.) The following example
shows how to make a hard copy of message #4 by using the PRINT
command:
MAIL> 4
#4 4-AUG-1985 09:39:20 MAIL
From: SPARTA::FELLINI
To: MARSTON
Subj: Rydell's Reasons
In reference to the meeting of July 26, I would like to explain
Rydell's opinion more fully...
MAIL> PRINT
You have already started using the eleventh MAIL command listed,
HELP. The next HELP topic to look at is "Folders". "Folders"
discusses the organization of the Mail Utility in detail. For more
information about each MAIL command, you can keep using the HELP
facility provided in MAIL or you can see the VAX/VMS Utilities
Reference Volume.
When you are ready to leave MAIL, enter the EXIT command and press
RETURN. Any messages marked for deletion will disappear. Any
messages marked for printing will enter the print queue and the
following message will be displayed:
MAIL> EXIT
Job 790 entered on queue ATLAS_PRINT