You are planning to shut down the system tomorrow at 3:00 p.m. because your CE is coming in to install the new disk drive you have been eagerly awaiting. How can you remind your users of this event?
There are several ways, but the one I like best is to do a quick change to the sign-on display. It is not as difficult as it sounds, especially if you include messages from a message file. Simply follow these steps:
1. Copy the source code for the IBM-supplied sign-on display. You will find it in member QDSIGNON in file QGPL/QDDSSRC. Do not, under any circumstances, change the original source. Your copy should have a different name and should be in a different library - preferably a library you created yourself. Let's pretend that you have called your source member MODSIGNON and have placed it in file YOURLIB/QDDSSRC.
2. Create a message file in YOURLIB. For example, we can call it SGNONDMSGF. This message file will contain all the messages that are to be displayed on the sign-on display.
3. Run SDA on your copy and change it as you see fit. Do not alter the length and order of the fields; do not delete them either. If you do not want to have a field displayed, put a DSPATR(ND) on it.
4. Add as many output fields as you need for the message that is to appear on the sign-on display. You can put these messages anywhere, and they can be as long or short as you desire. They can also have whatever display attributes you want: high intensity, underline, color, and so on.
5. Each message field must have the MSGID keyword indicating which message is to be displayed on that field. Suppose you defined three seventy-nine-character message fields on the sign-on display, named MSG1, MSG2, and MSG3. Your DDS should look like 7.
5. Each message field must have the MSGID keyword indicating which message is to be displayed on that field. Suppose you defined three seventy-nine-character message fields on the sign-on display, named MSG1, MSG2, and MSG3. Your DDS should look like Figure 7.
6. Compile your DDS. It does not matter if the message file exists or not, or whether it has the messages being referenced. The CRTDSPF command merrily does its work without a problem.
7. Now add messages SGN0001, SGN0002, and SGN0003 to file YOURLIB /SGNONDMSGF using the ADDMSGD command. Feel free to type whatever text you feel is appropriate for these message fields. If you do not want to display any messages, add blank messages; the messages being referenced by the sign-on display must exist in the message file.
8. Now change your subsystem description to start using your sign-on display instead of IBM's. To do so, you have to end the subsystem, change it with SGNDSPF (YOURLIB/MODSIGNON), and start the subsystem again.
From this point on, it is very simple to change what the sign-on display shows for these messages. Simply run a CHGMSGD to change the text; the new version of the text will appear next time you start the subsystem, or next time you vary on a particular display station.
Returning to our hypothetical case, then, you would simply do the following:
a) ENDSBS SBS(QINTER) b) CHGMSGD MSGID(SGN0001) + MSGF(YOURLIB/SGNONDMSGF) + MSG('Warning:') c) CHGMSGD MSGID(SGN0002) + MSGF(YOURLIB/SGNONDMSGF) + MSG('The system will + be shut down at 3:00 PM + tomorrow to install') d) CHGMSGD MSGID(SGN0003) + MSGF(YOURLIB/SGNONDMSGF) + MSG('a new disk drive. + Please plan your computer + work accordingly.')
TechTalk: Messages on the Sign-On Display
Figure 7 Sample message display file
Figure 7: Sample Message Display File 6...1.... ....2.... ....3.... ....4.... ....5.... ....6.... ....7 A MSG1 79A O nn nnDSPATR(HI) A MSGID(SGN0001 SGNONDMSGF) A MSG2 79A O nn nnDSPATR(HI) A MSGID(SGN0002 SGNONDMSGF) A MSG3 79A O nn nnDSPATR(HI) A MSGID(SGN0003 SGNONDMSGF) 6...1.... ....2.... ....3.... ....4.... ....5.... ....6.... ....7