When you implement a trigger for AS/400 systems, it is important to retrieve, edit and create a Workstation Customizing Object (WSCST). In the following procedure, LUNE is the WSCST name. It is recommended that you use a descriptive name such as the name of your document (for example, INVOICE or CHECK).
To retrieve the WSCST source:
At the command line, enter RTVWSCST and press ENTER.
At the Device type line, enter *TRANSFORM and press ENTER.
The following window appears.
Enter the following data:
Press ENTER.
A confirmation message appears.
Member SRCLUNE added to file QTXTSRC in OBJLUNE.
To edit the WSCST source:
At the command line, enter STRSEU and press F4.
The following window appears.
Enter the source file name. For this example, QTXTSRC.
Enter the library name. For this example, OBJLUNE.
Press ENTER.
The following window appears.
In the Opt column, enter 2 and press ENTER.
The following window appears.
Replace INITPRT DATA = ' 00 ' X. by the following INIT string:
:INITPRT
DATA =
'1B252D31323334355840504A4C20656E746572206C616E67756167'X
'65203D20506F73747363726970740D0A'X
'28464F524D292072756E20464F524D0D0A'X.
The INITPRT string is the hexadecimal representation of the trigger. In the example, the trigger is:
<ESC>%-12345X@PJL ENTER LANGUAGE=POSTSCRIPT
(FORM) run FORM
In the example, the name of the document is FORM. Note: The bold characters in the INITPRT string are the letters FORM in hexadecimal (where 46=F, 4F=O, 52=R and 4D=M). Consult ASCII Conversion Table for help translating your trigger into hexadecimal.
7. | Enter the RESETPRT DATA as displayed in the following window: |
:RESETPRT
DATA ='1B252D313233343558'X.
The INITPRT string is the hexadecimal representation of the following trigger:
<ESC>%-12345X@PJL ENTER LANGUAGE=POSTSCRIPT
(FORM) run FORM
8. | Press ENTER. |
The following confirmation message appears:
Member SRCLUNE in file OBJLUNE/QTXTSRC changed with 19 records.
9. | Press F3 to save the new WSCST. |
The following window appears.
10. | In the Change/create member line, enter Y, and press ENTER to confirm the save. |
The following confirmation message appears.
Member SRCLUNE in file OBJLUNE/QTXTSRC changed with 19 records.
To create the WSCST:
At the command line, enter CRTWSCST and press F4.
The following window appears.
Press F10 to display additional parameters.
Enter the name of the workstation customizing object that you want to create, and the library name for the customizing object (the one previously changed).
In the Additional Parameters section, enter the following:
The following confirmation message appears.
The object LUNE customization has successfully been created.
If the creation of the WSCST was not successful, verify that the hexadecimal code for the INITPRT and RESETPRT strings is correct. Once you create the WSCST, you can use it in an output queue.