Net Print/400 Frequently Asked Questions
Issue
1. How do you change the way the resulting CGI list looks?
Solution
The netprtsp.d2w Net.Data macro is completely customizable to meet the
usability requirements of your site. As a result, it is possible to
modify the macro source to format the resulting list, as well as the
rest of the query and results pages, to have the look and feel you
desire. The only restriction is within the Net.Data capabilities
themselves. I/NET also recommends that users duplicate the macros in
another IFS directory for customization, as the application of PTFs
may overwrite macros in the product folder, eliminating all
customization that may have been performed.
Issue
2. How do you set up your own link to print a report?
Solution
The NETPRTIB program is easily called (via a URL) directly from the
browser. It accepts parameters as named query string values. As a
result, the format of your link should look something like
<a href=/cgi-bin/netprtib.pgm?NAME=value&NAME=value&EXT=.np>Print report</a> . The parameter names can be found in Chapter 5 of the Net
Print/400 User Guide. Keep in mind that the &MFRTYPMDL parameter will
be fixed in your link and must reflect the printer that the browser
user will actually use to print the report. It is also important to
note that the portions of the URL that relate to the NETPRTIB program
(e.g. /cgi-bin/netprtib.pgm ) relate to the server type and
configuration elements put in place for the execution of Net Print/400
via CGI.
Issue
3. What configurations do I need to add to run Net Print/400 within
Netscape Enterprise Server?
Solution
Netscape Enterprise Server provides two ways to store CGI programs on your server machine:
- Specify a directory that contains only CGI programs. All files are run
as programs regardless of the file extensions.
- Specify that CGI programs are all a certain file type. That is, they
will all use the file extensions .cgi, .exe, or .bat. The programs can be
located in any directory the server can serve from.
There are benefits to either implementation. If you want only a
specific set of users to be able to add CGI programs, keep the CGI
programs in specified directories and restrict access to those
directories. If you want to allow anyone who can add HTML files to be
able to add CGI programs, use the file type alternative. Users can
keep their CGI files in the same directories as their HTML files.
If you choose the directory option, your server will attempt to
interpret any file you place in that directory as a CGI program. By
the same token, if you choose the file type option, your server will
attempt to process any files with the file extensions .cgi, .exe, or
.bat as CGI programs. If a file has one of these extensions but is not
a CGI program, an error occurs when a user attempts to access it.
The Net Print/400 documentation includes specific examples for
configuring each type of server (Commerce Server/400, Web Server/400,
Netscape Enterprise Server for the IBM AS/400, IBM HTTP
Server). Please refer to the "Configuration of CGI Environments"
chapter for additional assistance.
Issue
4. Where and how do I get the Net Print/400 plugin?
Solution
The Net Print/400 plugin is shipped with the product and is installed
in the product home folder (/QDLS/NPW). It can also be easily retrieved
from the I/NET website by following this link.
Once downloaded, execution of the executable (.exe) file will install
the helper application and place plugin files in the appropriate
directories for your Netscape and Microsoft browsers. Additional
information, including specific installation instructions, can be
found in Chapter 6 of the product documentation.
Issue
5. What kinds of reports can be printed with Net Print/400?
Solution
Typically, the style of reports available for printing via Net
Print/400 include *AFPDS and *SCS type of spooled files. The actual
report may include graphical, bar-code, some overlay, and many textual
types of data. This includes many different types of reports —
including invoices, sales analysis and reports, customer order
acknowledgements, distribution results, shipping label and list
reports, and many others.
Issue
6. What environments can Net Print/400 be used in?
Solution
Net Print/400 is a cooperative product - having some aspects that
execute on an AS/400 and some that run with a personal computer (PC) web
browser.
On your AS/400:
- You must be running OS/400 V3R2, V3R7 or above.
- Net Print/400 will run interactively using Webulator/400 version 2.0.
- Can run in a CGI environment with the Net.Data sample macro provided. Available servers available for use with Net Print/400 include:
- Commerce Server/400
- Web Server/400
- Netscape Enterprise Server for the IBM AS/400
- IBM's HTTP Server
- ICS/400
- ICSS/400
On your PC:
- You must be using Windows 95/98/NT.
- Works within Netscape Navigator/Communicator version 3.x, 4.x.
- Works within Internet Explorer version 4.x, 5.x.
Within a Webulator/400 session, it is also possible to transmit
reports from a second AS/400 using remote workstation pass-through
(the STRPASTHR command). As long as Net Print/400 is installed on the
target pass-through machine, the resulting spooled file data will be
transmitted through the source system's Webulator session to the
browser.
Issue
7. What kinds of reports can be displayed with Net Print/400?
Solution
Net Print/400 supports returning formatted data from spooled files in
an HTML display mode. By default, the product maintains the spooled
file's line spacing, bold, underline, and other attributes supported
by the HTML markup language.
While typically supported for printing within Net Print/400, graphic,
binary, and bar code data are not supported for display and it is not
recommended that they be contained in a spooled file that will be
displayed using the *HTML option. Displaying a spooled file via HTML
goes through the same transformation as for printer destined
requests. The printer type and model that is internally used for this
is an Epson FX-850 and display capabilities are limited to this style
of printer.
Issue
8. How does Net Print/400 get the list of reports?
Solution
Very much like the standard AS/400 'Work with Spooled Files' (WRKSPLF)
command, the Net Print/400 WRKSPLFNP command uses internal AS/400 APIs
to obtain the report list. Specifically, the QUSLSPL (List Spooled
Files) system API, among others, is used to retrieve spooled file list
entries for a given user or output queue. Concequently, the results of
the Net.Data macro are generated in the exact same way.
Issue
9. How do I print or save multiple copies of a report?
Solution
The Net Print/400 plugin includes a 'copies' option on the print
dialog box. This option will generate multiple copies of the report
requested, or will provide for multiple iterations of the report data
within the file where the report is saved.
Issue
10. What are the differences between Net Print/400 and LPR/LPD?
Solution
Net Print/400 allows for seamless ad-hoc printing of AS/400 reports
over the Internet. It does not require complex host or client setup to
generate reports. Interfaces exist for simple report
selection. LPR/LPD report printing involves the installation and
configuration of a Line Print Daemon on the PC to receive reports. It
also requires the assistance of an AS/400 administrator to configure
an output queue that will act as a Line Print Requester to send all
reports from that output queue to the LP Daemon. LPR/LPD must be
configured on the AS/400 and PC before printing can take place. There
is also no simple way to make LPR/LPD dynamic for report printing at
various clients.
Issue
11. I get "document contains no data" when trying to run NETPRTIB. What
is happening and why does this fail?
Solution
This situation is the probable result of an internal program error
within the server or within Net Print/400 which caused a response to
the browser without writing any data. Error messages may have been
sent to the server joblog that will be instrumental in the diagnosis
of the problem. Collect this data prior to contacting your system
administrator or support organization.
Issue
12. The message service program ——— not found is displayed when I try to
run Net Print/400. Why?
Solution
This is typically the result of executing the Net Print/400 product
without having added the Net Print/400 product library to the job's
AS/400 library list. This may be the interactive job's library list
(for Webulator/400 sessions) or the server job's library list (for CGI
sessions). Special care should be taken to add the appropriate product
library (usually NETPRTINET) to the library list prior to making any
spooled file requests.
A derivative of this may be a change in the server's current library
if you have previously set NETPRTINET as the current library. In some
circumstances, the server changes the current library to match that of
the called CGI, replacing the NETPRTINET entry. This is particularly
prevelent during the processing of the netprtsp.d2w Net.Data macro,
when the server may change the current library to the location of the
DB2WWW program. The product library must be added as a part of the
job's library list, and not reliant on being the current library.
Issue
13. Is there a way to save printer selections so I don't have to remember
them each time I print a report?
Solution
Yes - the netprtsp.d2w Net.Data macro provided saves the printer
selections in a browser cookie for use in future Net Print/400
sessions. In a similar fashion, as part of the SNDSPLFNP
functionality, the NETPRTIB program saves printer selections for
Webulator/400 users in an internal AS/400 data area (one data area for
each user). These selections may be accessed in subsequent sessions by
using the MFRTYPMDL(*USRPRF) parameter option.
Issue
14. I get "application not found" when trying to print a report. What
is happening and why does this fail?
Solution
This may occur if the Net Print/400 plugin has been manually removed
or is not currently available. Remote possibilities include storage of
the plugin on a networked drive that is not currently connected.
Issue
15. The printer that is connected to my PC is not listed. What can I do?
Solution
In addition to supporting the specific Manufacturer types and models
listed in the Net.Data macro and in the SNDSPLFNP command, Net
Print/400 can also support other MFRTYPMDL combinations that may be
available on your AS/400. This is dependent on OS/400 printer
availability. You should refer to the CRTDEVPRT command for additional
assistance on other printers that may be used.
Net Print/400 also supports Workstation customization objects and
AS/400 device descriptions for use in the spooled file transformation
process. These objects can be created to reflect the specific
attributes of a printer that may not be listed in the Manufacturer
type and model parameter or entry.
Issue
16. My printer settings are not being remembered in subsequent sessions. Why?
Solution
This is possible in either the Webulator/400 or CGI/Net.Data environments
and is related most to authorities provided.
In a Webulator/400 session, the printer selections are stored in a
data area within the Net Print/400 product library. This library is
typically named NETPRTINET. If the user that is executing the
SNDSPLFNP command does not have authority to create this data area (or
modify an already existing data area) the settings can not be
saved. Make sure that the interactive user has sufficient authority to
create the data area in the product library to correct this situation.
In a CGI environment, the printer selections are stored in a browser
cookie. If the browser settings are such that cookies are not allowed,
or if the cookie was rejected, these settings cannot be stored. Check
the browser configuration to ensure acceptance of the cookie.
Issue
17. Nothing happens when trying to print a report via Internet Explorer
in a Webulator/400 session.
Solution
It is possible that there are multiple installs of Internet Explorer
on your PC and the Net Print/400 plugin is registered to a different
one than you are executing. Take a look at the registered plugins for
your IE application. You can do this by editing the Windows registry
(run regedit) and looking at the following area:
HKEY_LOCAL_MACHINE/SOFTWARE/Microsoft/Internet Explorer/Plugins/MIME
View each plugin listed below the "MIME" level and list them with
their Extension information. Also, it is very important to make sure
that you do not modify the registry while running the regedit
program. To correct this, simply copy the plugin file from the
registered copy of IE to the Plugins directory of the IE that you are
running. The next time you start Windows, the registry entries should
automatically be added.
It's also remotely possible that the registry information is imported
from a corporate master that does not include Net Print/400. In this
case, a review of the Net Print/400 application with corporate IT
personnel should take place to potentially include the registration of
the Net Print/400 plugin in the master registry information.
|