Displaying Messages

Just because you send a message to someone doesn't guarantee that the other person is going to read the message. For example, the other person might not be signed on, or might be away from his display station. Even if the recipient is signed on and using the display station, under normal circumstances, the system does not automatically display the message.

The recipient is notified of the message by a beep, and the "message waiting" indicator on the screen turns on. The recipient can then request to display the message at a convenient time.

The DSPMSG Command

Run the Display Message (DSPMSG) command to display the contents of a message queue. You specify which message queue using the MSGQ parameter. If you do not specify which message queue you want to display, DSPMSG uses the default value *WRKUSR, which gives you both your own user profile and display station's message queues. This feature is convenient because it lets you display your own messages by keying in DSPMSG and pressing Enter. When you run DSPMSG, you see the panel shown in Figure 8.1.

image from book
Figure 8.1: User messages.

Although you also can use special values *USRPRF and *WRKSTN to display either (but not both) your own user profile and display station's message queues, these special values are seldom used. It is much easier to let DSPMSG give you both queues by not keying in any value.

You can enter any message queue name you want (and have authorization to) in the MSGQ parameter, including QSYSOPR. You also can display QSYSOPR's message queue by keying in the value QSYSOPR or *SYSOPR. Because an asterisk is harder to type than the letter "Q" (the asterisk requires the Shift key), *SYSOPR is not of much value.

You can use other parameters in the DSPMSG command, but they aren't as important as the MSGQ parameter. For example, you can specify where to begin displaying the messages. You can display at the top or at the bottom of the message queue, using the START parameter's *FIRST and *LAST values. The default value is *LAST.

Function Keys in DSPMSG Panel

The DSPMSG command panel offers several function keys, including three to remove messages from the message queue. Use these function keys carefully.

  • F11. If you move the cursor to a message and press F11, the system removes that particular message from the message queue. Do not do this on an inquiry message that has not been replied to already, or you will lose your opportunity to reply to the message.

  • F13. Removes all messages without exception, including unanswered inquiry messages. All unanswered inquiry messages are replied to with the default reply, which might be inappropriate. The system then removes both the original message and the reply. You have no way of knowing what the system did. Avoid using F13 at all costs.

  • F16. Removes all messages, except unanswered inquiry messages. This key is the safest way to clean up the message queue. You should get in the habit of pressing it as soon as you read newly arrived messages.

IBM i5/iSeries Primer(c) Concepts and Techniques for Programmers, Administrators, and Sys[... ]ators
IBM i5/iSeries Primer(c) Concepts and Techniques for Programmers, Administrators, and Sys[... ]ators
Year: 2004
Pages: 245

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net