IBM Support

Forcing Auto Select for Drawer Selection Using Host Print Transform (HPT)

Troubleshooting


Problem

This document provides information on forcing spooled files to print with "Auto Select" for the drawer selection when using Host Print Transform (HPT) to print to a PCL-capable laser or ink jet printer.

Resolving The Problem

This document provides information on forcing spooled files to print with "Auto Select" for the drawer selection when using Host Print Transform (HPT) to print to a PCL-capable laser or ink jet printer. This is done by retrieving and modifying a Workstation Customization Table (WSCST) and changing the Customizing Paper Drawer Selection (DWRSLT) tags for DRAWER1 and DRAWER2, as well as the Additional Drawer Table Entry (ADDDRWTBLE) tags, to send a particular value for the HP PCL Paper Source command.

For more information, refer to the following documents:

N1019453: Drawer Selection Considerations Database 'DCF Technotes (IBM i)', View 'Products', Document 'Drawer Selection Considerations'
N1010133: Drawer Redirection for HP PCL5 Compatible Printers Database 'DCF Technotes (IBM i)', View 'Products', Document 'Drawer Redirection for HP PCL5 Compatible Printers'
N1019423: Controlling and Troubleshooting Drawer Selection in a WSCST Database 'DCF Technotes (IBM i)', View 'Products', Document 'Controlling and Troubleshooting Drawer Selection in a WSCST'
N1014523: List of Common HP PCL5 Commands used by Host Print Transform (HPT) Database 'DCF Technotes (IBM i)', View 'Products', Document 'List of Common HP PCL5 Commands Used by Host Print Transform (HPT)'

This document was last updated on 24 December 2013.

Caution: These instructions are provided as is. Any assistance with editing the Workstation Customization Table must be done through a consulting agreement.
    • - Basic Steps for Creating and Using a Workstation Customization Object



      The following are the basic steps for creating and using a Workstation Customization Object (WSCST). Regardless of the particular issues you are attempting to resolve, these steps must always be taken. This information is intended to provide a 'quick start' to creating a WSCST object for users who have at least some familiarity with creating them and with configuring printers.

      Note: Additional, in-depth details for creating a WSCST object can be found in the following document:

      N1010140: Instructions for Modifying a Workstation Customizing Object (WSCST) Database 'DCF Technotes (IBM i)', View 'Products', Document 'Instructions for Modifying a Workstation Customizing Object (WSCST)'

      The following are the basic 'quick start' steps.

        • - Step 1: Retrieve the WSCST Source Code



          Retrieve the WSCST source code. Type the following command on the operating system command line:

          Important Note: Use the Manufacturer type and model (MFRTYPMDL) that is appropriate for your printer. Also, the Source member (in the following example, HP4) is a name that is appropriate to your customizing object. This is what you will be calling your workstation customizing object in Step 3.

          RTVWSCST DEVTYPE(*TRANSFORM) MFRTYPMDL(*HP4) SRCMBR(HP4)
                   SRCFILE(QGPL/QTXTSRC)

          Press the Enter key.

          • - Step 2: Edit the WSCST Source Code



            Edit the source code by using PDM or SEU:

            oTo use PDM, on the operating system command line type the following:

            WRKMBRPDM FILE(QGPL/QTXTSRC) MBR(HP4)

            Press the Enter key. Select Option 2 to edit.
            oTo use SEU, on the operating system command line type the following:

            STRSEU SRCFILE(QGPL/QTXTSRC) SRCMBR(HP4)

            Press the Enter key.
            Make any changes necessary to the WSCST object source code. Refer to the following section Customizing the INITPRT and RESETPRT Tags to make your changes, then save and exit. Continue with Step 3.

            • - Step 3: Create the *WSCST Object



              Create the WSCST object using the CRTWSCST command. On the operating system command line type the following:

              Important Note: Match the SRCMBR name from Step 1 to the WSCST object name that is created in this step.

              CRTWSCST WSCST(QGPL/HP4) SRCFILE(QGPL/QTXTSRC)

              Press the Enter key.

              • - Step 4: Specify the *WSCST Object in the Printer Device, RMTOUTQ or Printer Session



                Add the WSCST to the printer configuration by using the Change Device Print command (CHGDEVPRT), the Change Output Queue command (CHGOUTQ), or by changing the PC5250 printer emulation session configuration.

                oTo add the WSCST to a device description, on the operating system command line type the following:

                CHGDEVPRT DEVD(device_name) TRANSFORM(*YES) MFRTYPMDL(*WSCSTLETTER)
                          WSCST(QGPL/HP4)

                Press the Enter key.
                oTo add the WSCST to a remote output queue description, on the operating system command line type the following:

                CHGOUTQ OUTQ(queue_name) TRANSFORM(*YES) MFRTYPMDL(*WSCSTLETTER)
                        WSCST(HP4)

                Press the Enter key.
                oTo add the WSCST to a PC5250 printer emulation session, do the following:

                a In the PC5250 printer session, click on Communication > Configure.
                b Click on the Setup button.
                c In the Configure PC5250 Printer Emulation window, select the box next to Transform Print Data to ASCII on the iSeries and select the Printer Model value of *WSCST.
                d In the same window, specify the name of the WSCST in the Customizing Object parameter and the library where it is found in the Library parameter (for example, Customizing Object HP4 and Library QGPL).
                e Click OK three times.
                f Click File > Save to save the configuration.

                Note: If any changes are made to the WSCST object source code after the CRTWSCST command has been issued, it is necessary to issue the CRTWSCST command again. The printer writer must be ended and restarted for the changes to take effect.





            • - Pre-Built Workstation Customizing Object (WSCST) for Forcing Auto Select for Drawer Selection



              Rochester Support Center knowledgebase document New contains a save file with pre-built Workstation Customizing Objects (WSCSTs) for some of the most requested and most helpful customizations. The attached save file includes a pre-built WSCST object called PCL5AUTOSL that sends a PCL5 Paper Source command for auto-select ('1B266C3748'X or Esc&l7H) on most newer PCL-capable printers, and the PCL5AUTOS2 WSCST sends no PCL5 Paper Source commands at all. The result should typically be that the printer selects the default paper tray.

              For more information, refer to the following document:

              N1019007: Pre-Built Workstation Customizing Objects (WSCSTs) from IBM iSeries Remote Technical Support Database 'DCF Technotes (IBM i)', View 'Products', Document 'Pre-Built Workstation Customizing Objects (WSCSTs) from IBM System i Remote Technical Support'



            Method 1 - Modified *WSCST Source Code to send an HP PCL Paper Source Command to Use "Auto Select"

            Edit the Workstation customizing object (WSCST) source member, and find the Customizing Paper Drawer Selection (DWRSLT) and Additional Drawer Table Entry (ADDDRWTBLE) tags in the table. For example, you can type DWRSLT and ADDDRWTBLE on the SEU command line and press the F16 key). The DWRSLT tags tell HPT the HP PCL5e commands to send to the printer to select the manual feeder (PAPER) or envelope feeder (ENVELOPE), or when the Source Drawer (DRAWER) parameter in the spooled file attributes is set to 1 (DRAWER1) or 2 (DRAWER2). The ADDDRWTBLE tags tell HPT the HP PCL5e commands to send to the printer when the Source Drawer (DRAWER) parameter in the spooled file attributes is set to a 3 or higher.

            The following table shows the original settings DWRSLT and ADDDRWTBLE tags from the WSCST source code for a Manufacturer type and model (MFRTYPMDL) setting of *LEXOPTRAT, and the values to use to send an HP PCL5e Paper Source command for Automatic drawer selection ('1B266C3748'X).

            Original DWRSLT and ADDDRWTBLE Tags for *LEXOPTRATDWRSLT and ADDDRWTBLE Tags for Auto-Select
               :DWRSLT
                 DRAWER=PAPER
                 DATA ='1B266C3248'X.    
               :DWRSLT
                 DRAWER=ENVELOPE
                 DATA ='1B266C3668314F'X.
               :DWRSLT
                 DRAWER=DRAWER1
                 DATA ='1B266C3148'X.
               :DWRSLT
                 DRAWER=DRAWER2
                 DATA ='1B266C3448'X.
               :DWRSLT
                 DRAWER=PAPER
                 DATA ='1B266C3248'X.    
               :DWRSLT
                 DRAWER=ENVELOPE
                 DATA ='1B266C3668314F'X.
               :DWRSLT
                 DRAWER=DRAWER1
                 DATA ='1B266C3748'X.
               :DWRSLT
                 DRAWER=DRAWER2
                 DATA ='1B266C3748'X.
               :ADDDRWTBL.
               :ADDDRWTBLE
                 NUMBER=    3
                 DATA ='1B266C3548'X.
               :ADDDRWTBLE
                 NUMBER=    4
                 DATA ='1B266C323048'X.
               :ADDDRWTBLE
                 NUMBER=    5
                 DATA ='1B266C323148'X.
               :EADDDRWTBL.
               :ADDDRWTBL.
               :ADDDRWTBLE
                 NUMBER=    3
                 DATA ='1B266C3748'X.
               :ADDDRWTBLE
                 NUMBER=    4
                 DATA ='1B266C3748'X.
               :ADDDRWTBLE
                 NUMBER=    5
                 DATA ='1B266C3748'X.
               :EADDDRWTBL.

            To create the WSCST object and implement it, perform Steps 3 and 4 (above).


            Method 2 - Modified *WSCST Source Code to not send any HP PCL Paper Source Commands

            Edit the Workstation customizing object (WSCST) source member, and find the Customizing Paper Drawer Selection (DWRSLT) and Additional Drawer Table Entry (ADDDRWTBLE) tags in the table. For example, you can type DWRSLT and ADDDRWTBLE on the SEU command line and press the F16 key). The DWRSLT tags tell HPT the HP PCL5e commands to send to the printer to select the manual feeder (PAPER) or envelope feeder (ENVELOPE), or when the Source Drawer (DRAWER) parameter in the spooled file attributes is set to 1 (DRAWER1) or 2 (DRAWER2). The ADDDRWTBLE tags tell HPT the HP PCL5e commands to send to the printer when the Source Drawer (DRAWER) parameter in the spooled file attributes is set to a 3 or higher.

            The following table shows the original settings DWRSLT and ADDDRWTBLE tags from the WSCST source code for a Manufacturer type and model (MFRTYPMDL) setting of *LEXOPTRAT, and the values to use to not send any HP PCL5e Paper Source command, which should result in the printer hardware using its own default paper source.

            Original DWRSLT and ADDDRWTBLE Tags for *LEXOPTRATDWRSLT and ADDDRWTBLE Tags for Auto-Select
               :DWRSLT
                 DRAWER=PAPER
                 DATA ='1B266C3248'X.    
               :DWRSLT
                 DRAWER=ENVELOPE
                 DATA ='1B266C3668314F'X.
               :DWRSLT
                 DRAWER=DRAWER1
                 DATA ='1B266C3148'X.
               :DWRSLT
                 DRAWER=DRAWER2
                 DATA ='1B266C3448'X.
               :DWRSLT
                 DRAWER=PAPER
                 DATA ='1B266C3248'X.    
               :DWRSLT
                 DRAWER=ENVELOPE
                 DATA ='1B266C3668314F'X.
               :DWRSLT
                 DRAWER=DRAWER1
                 DATA =''X.
               :DWRSLT
                 DRAWER=DRAWER2
                 DATA =''X.
               :ADDDRWTBL.
               :ADDDRWTBLE
                 NUMBER=    3
                 DATA ='1B266C3548'X.
               :ADDDRWTBLE
                 NUMBER=    4
                 DATA ='1B266C323048'X.
               :ADDDRWTBLE
                 NUMBER=    5
                 DATA ='1B266C323148'X.
               :EADDDRWTBL.
               :ADDDRWTBL.
               :ADDDRWTBLE
                 NUMBER=    3
                 DATA =''X.
               :ADDDRWTBLE
                 NUMBER=    4
                 DATA =''X.
               :ADDDRWTBLE
                 NUMBER=    5
                 DATA =''X.
               :EADDDRWTBL.

            [{"Type":"MASTER","Line of Business":{"code":"LOB57","label":"Power"},"Business Unit":{"code":"BU058","label":"IBM Infrastructure w\/TPS"},"Product":{"code":"SWG60","label":"IBM i"},"Platform":[{"code":"PF012","label":"IBM i"}],"Version":"6.1.0"}]

            Historical Number

            603484665

            Document Information

            Modified date:
            18 December 2019

            UID

            nas8N1011472