× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Dear Brad,

I forwarded your question about Print Text to Rodney Johnson at IBM. One of
his primary duties is working with the spooling capabilities of OS/400. He
frequently answers questions in the comp.sys.ibm.as400.misc newsgroup. His
answer to your question is appended below.

Best Regards,

/Paul
/Paul
--
Paul Tykodi
Director, Printer Connectivity Product Management
LCI-Intermate US, Inc.

p: 603.431.0606 x115
f: 603.436.6432
paul@intermate-us.com
www.intermate.com

-----Original Message-----
From: Rodney Johnson [mailto:rodaj@us.ibm.com]
Sent: Wednesday, October 10, 2001 5:09 PM
To: Paul Tykodi
Subject: Re: FW: Print Text and Spooled Files



Paul, The print text is extracted from the job the spooled file is stored
under at the time the separator page is generated.  The print text within
the spooled file itself is extracted and put into the datastream at the
time the spooled file data is being written by the application (initial
creation).  The APIs QSPCRTSP and QSPPUTSP
 do not allow for the changing
of the print text within the spooled file data.  The data is written as is
without modification into a new spooled file making the data of the spooled
file a true duplicate (unlike some of the spooled files attributes...such
as create date/time, spooled file number, etc).

In order to have the print text changed for a spooled file, one would have
to read the data from the existing spooled file and then put the data to a
printer file (just like the application did) to get new print text.  The
tool would need to know what the old print text is to make sure it did not
write that data to the printer file.  Or, one other option would be to
modify the datastream in the user space before calling QSPPUTSP.  Of course
this could require modification of the structures for SPFR0200 to make
things work correctly, especially if the print text has a different number
of characters/bytes.  You would also have to be able to interpret and
generate the appropriate data stream commands as well (AFPDS, SCS, LINE,
IPDS, etc).  I suppose you could alter the data stream but use
PrintManager/400 instead of the Spool APIs (both are part of base OS).
This removes the complexities of figuring out QSPPUTSP, but still requires
knowledge of the specific data streams.

Generally changing the print text (or any text within a spooled file for
that matter) is not a simple task and generally is one you may want to stay
away from.

I've noticed a drop in participation in comp.sys.ibm.as400.misc.  Do you
happen to know what is prompting this?  I only monitor that one, as I only
can justify spending so much time each day to one bb.

Regards,
Rodney A. Johnson
AS/400 Spool
(507) 253-7925

>Message: 3
>From: "Brad Stone" <brad@bvstools.com>
>Subject: Print Text and Spooled Files
>To: midrange-l@midrange.com
>Date: Wed, 10 Oct 2001 11:08:38 -0500
>Reply-To: midrange-l@midrange.com
>
>I have a weird one here.
>
>One of my tools, SPL2SPL, allows a user to copy a spooled
>file.  It also allows them to change certain spooled file
>attributes for the new spooled file.
>
>Now, I have a couple users who use the Print Text paramter,
>and it does not seem to change the print text on the
>duplicated spooled file.

>I have run this in debug 100 times, and I can see that the
>print text parameter of the new spooled file HAS changed.
>But when the spooled file is printed, the print text from
>the original spooled file appears on the output instead of
>the new Print Text.

>The documentation on this field is sparse, so I'm at a loss
>as to why this isn't working.

<further information deleted>



As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.