Bottom of Page | Previous Page | Next Page | Contents

Enabling print support in projects

As you develop a HATS project, you can establish a print session for the associated host application. When the HATS project is running on a WebSphere server, an end user of the application can also print data or display data that is formatted for printing.

When interacting directly with a host application, an end user activates a physical printer to print data from the application. When interacting with a HATS application, the end user does not activate a physical printer. Rather, he or she generates an Adobe Portable Document Format (PDF) file, which can be displayed in a Web browser. The PDF file can also be printed.

Note:
If a PDF viewer (Adobe Acrobat Reader) is not installed, the user will be prompted to save the file to disk.

This chapter describes the process for enabling print support in your HATS project and for using print support as you develop the project in HATS Studio and as the application is used by an end user.

Configuring the host print session on 3270 hosts

Before setting up print support for your HATS project, make sure that you (or the system administrator) have performed the following configuration for the host print session:

Refer to the documentation for your 3270 host software for details on how to perform these steps.

Defining print support for your project

For print support to be available for your project, you must obtain the host name and the port number for the Telnet server from the system administrator. Enter these values when you define the connection settings for your project.

For 3270 servers

To define print support when your HATS project interacts with a 3270 server, do the following:

When an end user of the HATS application issues a command to print files, the HATS application sends a print job to the printer LU and the HATS runtime converts the print job to PDF format. Once the PDF is formatted, the end user can click View Print Jobs on the application keypad to see a list of queued print jobs.

To have more control over 3270 PDF print output format, you can add the following IBM WebSphere Host On-Demand connection session parameters to the list of connection settings:

CPI
Characters per inch. Specifies the number of characters printed per inch. On a Windows platform, three choices (10, 12, and 17) are available. The default value is 10.
LPI
Lines per inch. Specifies the number of lines per inch. On a Windows platform, five choices (2, 3, 4, 6, and 8) are available. The default value is 6.
MCPL
Maximum characters per line. Specifies the maximum number of characters per line, also called the Maximum Print Position or the Maximum Presentation Position (MPP). Enter a value from 1 to 255. The default value is 80.
MLPP
Maximum lines per page. Specifies the maximum number of lines per page, including the top and bottom margins. This value is also called Maximum Page Length (MPL). Enter a value from 1 to 255. The default value is 66.
RTLfile
Printing Right-to-left files. Specify "true" to print a file as it appears on a RTL screen. The default is "false."

For 5250 servers

To define print support when your HATS project interacts with a 5250 server, click the Enable print support checkbox in your project settings. Provide a URL for the iSeries for Web Access (IWA) Printer Output window. The default URL is http://hostname/webaccess/iWASpool, where hostname is the name of the 5250 server. See Advanced Connection Settings tab for more information.

You do not need to perform any additional configuration. When an end user of the HATS application issues a command to print files, IWA converts the host print jobs into PDF format and facilates the download to the end user. The end user can click View Print Jobs on the application keypad to display the IWA Printer Output window. In this window, the end user can select the following print options:

  1. PDF device type
  2. Paper size
  3. Destination

Refer to your IWA documentation for more information on these print options.

Providing documentation for end users

To facilitate use of your HATS project by end users, we recommend that you provide documentation on how to use the print support in HATS. Your documentation--provided either in the application's graphical user interface or in some other easily displayed form (perhaps a link in your template)--should describe:

To use HATS print support, an end user should follow these steps:

  1. Start the HATS application.
  2. Print the files.
  3. Click the View Print Jobs button. The Printer Output window displays a list of print jobs, if any exist.

    In the Printer Output window, the end user can click the links for their jobs to either View or Delete the print job. If the user clicks the view link, the print job is displayed as a PDF file in Acrobat Reader, if it is available. If not, the user is prompted to save the file to disk.

    Note:
    While the print jobs are spooling, the user might see the file names for the print jobs in the printer output window, but View and Delete are disabled until the conversion to PDF format is complete.
[ Top of Page | Previous Page | Next Page ]