FormSprint Manual
FormSprint Manual
FormSprint Manual
FormSprint Instructions
Table of Contents
Overview I-1
Software Loading Instructions I-3
Table of Contents i - 1
Integrated Custom Software, Inc.
Table of Contents i - 2
FormSprint Instructions
Spool Mapper Math 5-20
Page Number Function 5-21
Search and Replace Function 5-22
Dynamic Form Page and Tray 5-22
Page Select 5-24
Dynamic Output Tray 5-28
Variable Substitution Table 5-28
VR and VRM Functions 5-35
Table of Contents i - 3
Integrated Custom Software, Inc.
Table of Contents i - 4
FormSprint Instructions
Form Batch Processing Security Control 17-6
The Library and File Index 17-8
The EBCDIC/ASCII Translation Tables 17-9
Color Support 17-14
Language Selection 17-15
Table of Contents i - 5
FormSprint Instructions
Welcome to FormSprint!
The ICS FormSprint software will enable you to take data from any spool
file on the AS/400 and print it to any PCL laser printer in any format you
need. Briefly, the way FormSprint works is that you re-direct your spool file
to a special output queue created within the program. By means of a unique
FORMTYPE on your spool file, FormSprint recognizes what form is to be
processed and then follows the unique form layout instructions and mapping
of the data as defined for the particular form being processed. This Quick
Start chapter will take you through the creation of the output queue, the
definition of a simple form, and the mapping of a spool file and printing of the
form.
Let’s start at the very beginning – is your software loaded on your AS/400
yet? If not, please turn to the loading instructions at the beginning of this
book. You may also have been sent a separate sheet with Loading
Instructions. If you are doing a demonstration of FormSprint, you will need
date codes from ICS to activate the software. These codes may be found on
your loading instructions sheet, or just give us a call at ICS (860) 657-3339,
and we’ll be glad to get you going with your demo.
Once the software has been loaded, on a command line, enter CALL
ICSPROG/ICSMENU. If this is a demo, you will be prompted at this point for
the first of four date codes. Enter the code and press ENTER. The screen
shown in Figure QS-1 will be displayed. If you are not working with demo
software, please skip ahead to the next section and continue with this
QuickStart Tour. If you are working with demo software, please select Option
1 – FormSprint Editor. You will be asked for the next date code. Enter the
appropriate code and press ENTER. Cancel out of the Editor with F24 to
return to the Menu. Now select Option 2 – the FormSprint Link and enter
the third code. As soon as this is entered you will be asked for the fourth and
final code for the fax support module. This module demonstrates
FormSprint’s interface to several faxing solutions that use AS/400 APIs.
There are other fax solutions which do not require the fax support module,
you should check with your sales representative if you will be testing faxing.
If you are not going to be evaluating this option, delete the fax support
module (WRKOBJ OBJ(*ALLUSR/FFX*) then delete the three objects in the
ICS libraries).
If you are not already on the ICS Menu screen, enter the command CALL
ICSPROG/ICSMENU and hit ENTER. From the Menu select Option 3 for the
Job Controller and hit ENTER. The screen shown in Figure QS-2 will be
Quick Start - 1
Integrated Custom Software, Inc.
shown. If your subsystem has already been established and you have virtual
input queues active on your system, you will need to check with your system
administrator before changing or creating new virtual input queues.
To create your first virtual input queue, enter a 2 (to Change) on the first
available option line and press ENTER. The screen shown in Figure QS-3
will be displayed. Enter the name TESTQ for your first virtual input queue.
Enter the output queue name for the laser printer you will be using for testing
and change the library if it is not QUSRSYS. Keep or Delete input spool files
should be set to K to keep for our demo. The next parameter to change is
“Start Writer with Subsystem” - change this to Y for yes, leave all of the other
parameters as they default, then, press ENTER. Let’s set up one more
virtual input queue. Enter Option 2 again on the second line and press
ENTER. Enter another name perhaps in the format PRT01V with the output
printer queue being PRT01. Leave all of the defaults for now and press
ENTER. This step automatically creates the output queue, the data queue,
job class, priority, and routing entry.
The next step is to start your subsystem – select Function Key 15. You may
need to refresh your screen, but the status of the subsystem in the upper
right corner of your screen should now display “Active”. Notice that the first
virtual input queue (TESTQ) becomes Active while the second (PRT01V)
does not. This is because for TESTQ we changed the Start Writer with
Quick Start - 2
FormSprint Instructions
Quick Start - 3
Integrated Custom Software, Inc.
Select Option 1 from the ICSMENU for the FormSprint Editor. Select
Function Key 4 to Create a Form. The screen shown in Figure QS-4 will be
displayed. Enter the form name DEMOINV on the line provided and press
ENTER. This is the name that will be the link to the FORMTYPE parameter
on our spool file when we are ready to merge data with our form. The name
of the form does not need to be all caps, but the FORMTYPE parameter is
case sensitive and most spool files do have a FORMTYPE that uses upper
case letters.
On the next screen (Figure QS-5), the Printout Default Values, enter the
output queue name of your printer (not the name of your virtual input queue)
where you will be testing your form, press ENTER. You are now on the
Spool Mapper screen where we position the spool file data on the form, we’ll
be coming back here, but for now, press Function Key 1 for the Flash
definition (the fixed part of your form). The screen shown in Figure QS-6 will
Quick Start - 4
FormSprint Instructions
be displayed. Usually, but not always we begin the form design process in
the Flash definition.
Quick Start - 5
Integrated Custom Software, Inc.
Let’s stop for a moment to see how we move around within the form. All
selections within the FormSprint Editor are made with Function Keys. Note
that at the top of your screen FormSprint displays the form element you are
in (you should be in Vertical Lines at this point), and the location in the
format Page 1-1. The first 1 represents the form page number and the
second 1 represents the screen number. For example, if the screen said
Vertical Lines, Page 3-2, you would be working on Page 3 of the form on the
second screen of the vertical line definitions. There are several ways to
move from page to page and screen to screen. You can simply type the
page and screen destination at the top of the screen and press ENTER, or
you can scroll using function keys, or if you wanted to move from one screen
to another, use the Page Up and Page Down keys. Press Function Key 3
(next page) and you will see that you are now on Page 2-1. Press Function
Key 5 (next screen) and you will be on Page 2-2 (screen 2 on the second
page of the form). Function Keys 2 and 3 will scroll from Page to Page and
Function Keys 4 and 5 will scroll from screen to screen (or use Page Up and
Page Down). Another level within your form definition is the Macro. Press
F14 and you will see that you are now in Macro 1 screen 1. Macros work just
like pages, so to get to Macro 2 you would press F3 and to get back to
Quick Start - 6
FormSprint Instructions
Macro 1 you would press F2.To get out of Macros, press F14 and you will be
back on Page 1-1 of Vertical Lines.
The form we are going to build is pictured in Figure QS-7. Note that the form
has numbers printed on the tops, bottoms, left and right of each of the form
elements. The form design process is simplified when you measure these
parameters first and write them on your form. Let’s begin with boxes – press
F8 – Boxes. Enter the numbers just as they are pictured in Figure QS-8. On
the first line enter Left Edge 20 (this is 20mm from the left edge of the page),
Right Edge 190 (190mm, still measured from the left edge of the page), Top
100 (100mm from the top edge of the page), Bottom 200 (200mm again
measuring from the top edge of the page down), Width of 3 (this is the width
of the line around the outside of the box), and Density 100 (the outline is
100% black). The fill density would be used if we wanted our box to be
shaded inside, the number and spacing are used for creating more than one
box, for example, 2 for the number and horizontal spacing of 10 would
create two identical boxes spaced 10mm apart from start to start.
On the next line of boxes for left edge enter 20, for right edge enter 190, for
top enter 100, for bottom enter 110, for width enter 3, for density enter 100,
and for fill density, enter 10. This entry will create the shaded heading box
on our form. Let’s print to see how the boxes look. Press F15 to Print to
display the flash printout screen (Figure QS-9), then press ENTER.
Quick Start - 7
Integrated Custom Software, Inc.
Now we’ll put in our Vertical Lines – press F6. Make your entries just like
those on the screen shown in Figure QS-10. On the first line enter From left
of 50 (50mm from the left edge of the page), top 100 (the line begins 100mm
down from the top edge of the page), bottom 200 (the bottom of the line is at
200mm from the top edge of the page), enter a width of 3, and Density of
100 (100% black). Enter the rest of the lines in a similar fashion; From left
150, top 100, bottom 200, width of 3, Density of 100 (no need to enter
number and spacing unless you are replicating lines). The third entry should
read From left 170, top 100, bottom 200, Width of 3, Density of 100. Let’s
print again – select F15 to print then press ENTER. With two box entries and
three line entries, most of the form is built!
Press F7 now to go to Horizontal lines. Our form has three horizontal lines
spaced 8.5 mm apart. The screen shown in Figure QS-11 shows the entries
you should make. On the first line enter From top 50, left of 20, right 100,
width of 3, density 100, for Number enter a 3, and for Spacing enter 8.5 – all
three lines with one line of entry! Press F15 again followed by ENTER to see
what your form looks like. Next go on to Graphics, F9.
Press F9 with your cursor on the first line of the Graphic screen (Figure QS-
12). You will see the list of graphic files on your system. Bring your cursor
down to ICSLOGO to select this graphic. Now enter positioning of 20mm
Vertical and 20mm Horizontal with a Color/Scaling of 1. No need to enter
anything for number and spacing as this is only for repeating the graphic.
Quick Start - 8
FormSprint Instructions
Quick Start - 9
Integrated Custom Software, Inc.
Quick Start - 10
FormSprint Instructions
The Color/Scaling parameter gives you the ability to increase the size of the
graphic and to shade or invert the image. You might want to try making a
second entry of ICSLOGO at 132mm vertical and 30mm horizontal with a
Color/Scaling of 103. Press F15 followed by ENTER to print your demo form.
We’ve included three graphics (ICSLOGO, ICSLOGOS, and FLAG) for you
to play with on your demo form. You can easily incorporate your own
graphics by scanning as black and white line art, saving as TIFF files and
uploading to your AS/400 via Client Access and shared folders (please refer
to the chapter on graphic files).
The last thing we need to add to our form is text, press F10 for Text. The
screen shown in Figure QS-13 shows the entries we will be making. On the
first line enter the word INVOICE at 30mm from the top, 130mm from the left
with a font of 4148142, and a weight of 4. Text is always positioned to the
BOTTOM of the letter and the default justification is Left Justified. The font
we have selected is Univers and is a good choice for the fixed part of any or
all of your forms. The first four numbers of our font (4148) selected Univers,
the 14 selected the point size (how tall is the letter) and the 2 at the end
selects the upright Roman-8 symbol set. A weight of 4 makes the font bold.
Now enter the word ITEM. Place ITEM at 106mm from the top, 20mm from
the left, a font of 4148102 and a weight of 4. Now, you can see that we don’t
really want the word to be at 20mm from the left because it would be right on
the left side of the box. What we really want is for the word to be centered
Quick Start - 11
Integrated Custom Software, Inc.
over the column. To center the text, press ENTER and enter the right edge
of 50 and tab to the format and make that C for centered (as shown in Figure
QS-14). Press ENTER to return to the Text screen. FormSprint does a
perfect job of centering when you tell the program the left and right of the
area where you want the text centered.
Now enter ‘DESCRIPTION’ at From top 106, From left 50, font 4148102,
weight 4, press ENTER and make the Right edge 150, put a C for format.
For Unit Price and Total Price we are going to make a two line text entry.
Enter UNIT at From top 105, Left edge 150, font 4148102, weight 4, press
ENTER and make the Right edge 170, enter 6 for the lines per inch and
enter CN for the format. An entry of CN tells FormSprint to center and no
wrapping of text, so our two lines will stay as two separate lines. Then TAB
down below the word UNIT and type PRICE, then press ENTER. Finally,
enter TOTAL at From top 105, Left 170, font 4148102, weight 4, press
ENTER and make the Right edge 190, 6 lines per inch and CN for format.
Again, TAB down below TOTAL and type PRICE then press ENTER. This
text entry is shown in Figure QS-15. Let’s print the completed form – press
F15 and ENTER. Congratulations – yes, it’s a simple form but most forms
are just a variation on this simple invoice – a few more boxes, a few more
lines and bit more text, but a variation on the simple invoice!
Quick Start - 12
FormSprint Instructions
Figure QS-15 – Adding the letter “N” to the format, turns word wrapping off.
Of course our form isn’t really done – there’s no data! Let’s create a simple
spool file and merge it with our newly completed form. Press F24 to cancel
the FormSprint Editor program – YES we save everything, no need to press
ENTER at every screen change. Press F24 again once you are on the
FormSprint Editor menu. From the ICSMENU, select Option 8, the Spool
File Utility program. Select the Demo Invoice Sample with an Option 2 to
Edit. The screen shown in Figure QS-16 will be displayed. From the spool
file screen, press F15 to print. The screen shown in Figure QS-17 will be
displayed.
The first thing we are going to print is what we refer to as a SPOOL GRID.
The SPOOL GRID is a form, that gives us a layout of our spool file to tell us
where the data is positioned. Now, just as you will be doing once you are
using FormSprint in production, the output queue you enter on this screen
is the FormSprint Virtual Input Queue we created in the Job Controller.
Enter TESTQ in the output queue field, QUSRSYS for the library, SPOOL
GRID (yes, all upper case and do leave a space in the middle) for the
FORMTYPE. The FORMTYPE parameter is used by FormSprint to
determine what form to print (in this case, the SPOOL GRID form). Set the
status to “P” to put the spool file in RDY status. Because we have already
started your subsystem, your SPOOL GRID should be printing right now.
The GRID form will become a tool that allows you to “view” the spool file in
terms of the lines and columns where data prints. You will be using this form
Quick Start - 13
Integrated Custom Software, Inc.
Figure QS-17 – Press F15 to submit the file to TESTQ with the FORMTYPE
for SPOOL GRID.
Quick Start - 14
FormSprint Instructions
as you begin to map the data to your new invoice form. The SPOOL GRID
can be seen in Figure QS-18.
Figure QS-18 – The SPOOL GRID form is used to locate the positions of
data within the spool file.
Press F12 to cancel out of the Spool File Utility program and return to the
ICSMENU. Take Option 1 for the FormSprint Editor. Now select Function
Key 3 to Edit Form Definition. Place your cursor on the DEMOINV form and
press ENTER. You should now be on the Spool Mapper screen for your
demo form. Make entries as shown in Figure QS-19. The entry you make in
the Description field is simply documentation for you – it does not print. The
entry you make here should be in some way descriptive of what the step is
accomplishing – for example, Place Inv Number, or Check No Top, etc. In
our example we are saying DATA because all data will be placed by this one
entry. The next five columns refer to your spool file – page (or record) start
line and end line and then start column and end column. In our example,
because we are placing all data in one step, we simply include all lines (1-
66) and all columns (1-85).
The four columns on the right of the screen refer to your output page. “Page”
refers to the actual physical page to print on (Original might be page 1, a File
Copy might be page 2). The “From Top”, “From Left”, and “Right Edge” are
millimeter measurements of the exact placement of data on the page. By
selecting all lines and columns of data from our spool file, we have simply
given FormSprint a starting place by saying 10 mm from the top and left of
Quick Start - 15
Integrated Custom Software, Inc.
Figure QS-19 – The first Spool Mapper screen for the DEMOINV form.
our form. The entry of 207 on the right simply tells FormSprint to use the
whole printable area. Now its time to see how our completed form will look.
Press F24 to cancel out of the FormSprint Editor. On your command line,
enter WRKOUTQ TESTQ and press ENTER. You will see the spool file with
the SPOOL GRID formtype now back on HOLD in the output queue. You are
going to change the formtype to the name of your new invoice form –
DEMOINV. Select option 2 to change your spool file. Go to the Formtype
parameter field and type in the name of your DEMOINV and press ENTER
to make the change (Figure QS-20). Now simply release your spool file (type
option 6, and press ENTER). Because you’ve changed the formtype to your
DEMOINV, FormSprint will use your new form and should be printing it right
now - on your form!
Quick Start - 16
FormSprint Instructions
Figure QS-20 – Use the Change Spool file Attributes command to change
the FORMTYPE to DEMOINV.
Figure QS-21 – Make changes to the Spool Mapper to align and change the
font of the Invoice Number.
Quick Start - 17
Integrated Custom Software, Inc.
are now on the Fonts and Functions screen (Figure QS-22). This screen is
used for changing fonts in terms of typeface, boldness, lines per inch, pitch,
format, or rotation. Also, you could choose any type of bar code, you can
enter a special function or use FormSprint’s buffers (please refer to Chapter
4 for a discussion of bar codes and buffers). Make the entries as shown in
Figure QS-22 on the Fonts and Functions screen. Press ENTER to return to
the Spool Mapper screen. Enter the second line on the Spool Mapper to
position the rest of the data.
Figure QS-22 – Press ENTER on the Spool Mapper entry line to access the
Fonts and Functions screen.
Please note that when you begin to map separate fields on a form, you run
the risk of not printing certain data. The SPOOL GRID shows us a sampling
of data – there may be times when data prints at a location not shown in our
sample. Notice that in our example the address prints on lines 12 and 14.
Address lines are often formatted to leave a blank line if an optional address
line is not used. Therefore, when printing name and address fields, you may
want to include blank lines (like our line 13 in the example). Another
common example would be the use of “REPRINT” which might only appear
at the top of a form if the reprint option was selected when printing from the
application program. It is important, therefore, to know your spool file and
plan ahead for possibilities.
Quick Start - 18
FormSprint Instructions
Press F24 now to exit your form and the FormSprint Editor. Again, enter the
WRKOUTQ command for TESTQ (Figure QS-23). Simply release your spool
file as it already has the correct FORMTYPE (DEMOINV). Your new form
should be printing with the Invoice Number now lined up properly and font
changed.
Figure QS-23 – Use the WRKOUTQ command for the Virtual Queue and
release the sample spool file to test your changes.
Now let’s add the postal code as well. Begin by selecting the INPUT (line 14
– no need to select the columns FormSprint will pick out the numeric field
from the City, State and Zip line). Next, enter the OUTPUT location in
millimeters where the code will appear – the Post Office prefers the coding
to be above the name and address. Finally, press ENTER and simply put an
X by postal code. The height of this bar code is not scalable and must be
according to Postal specifications so there is no need to enter a height or
Quick Start - 19
Integrated Custom Software, Inc.
width. Follow the example in Figure QS-25 for the coding of the postal bar
code. Test your bar codes by exiting the Editor (press F24 twice), type the
WRKOUTQ command, and release your spool file again.
Notice how the comments are printing on our DEMOINV. The left and right
sides of the comments hang out on both sides of the detail box. Wouldn’t the
appearance of this form be improved if the comments lined up properly with
the sides of the box? No need to re-write your program, FormSprint can re-
wrap this text so it is properly aligned. Begin by changing the last line of the
detail data entry so that its last line is line 46 and not 66. Now make a new
entry called COMMENTS and select lines 47 to 66 (we don’t really know
how long the comments could be and sometimes they may go for more lines
than we have in the example). Next enter the OUTPUT location as follows:
207 from the Top, 20 from the Left (to line up with the left side of the box)
and 190 on the Right (to line up with the right edge of the box). Now, press
ENTER to go to the Fonts and Functions screen and select ‘J’ for the format.
A format of Justify will align both the left and right edges of your text, a
format of Wrap will align the left edge and leave the right edge ragged but it
will not extend beyond 190 (the right edge). Follow the example in Figure
QS-26 for this example.
Try some different mapping with your DEMOINV. Perhaps you could create
a remittance stub for the bottom of the form to be returned with payment.
Quick Start - 20
FormSprint Instructions
Figure QS-24b – Press ENTER on the Spool Mapper reference line – enter
a height and bar width and mark the symbology desired with an “X”.
Quick Start - 21
Integrated Custom Software, Inc.
Figure QS-25b – Press ENTER on the reference line and mark Postnet with
an “X”. No need to give a height or bar width.
Figure QS-26a – Next, align the comments below the invoice box.
Quick Start - 22
FormSprint Instructions
Figure QS-26b – Press ENTER to go to the Fonts and Functions screen and
select either “J-Justify” or “W-Wrap” to enable FormSprint to re-wrap the
comments text according to the Left and Right you have specified on the
Spool Mapper.
Follow the example shown in Figure QS-27 to create the stub at the bottom
of your form. Simply select each of the fields (Inv. No., Inv. Date, Name &
Address, Amt. Due) from the spool file and position them at the bottom of the
form along with any fixed text or boxes to create a return stub.
When you’ve made all of your modifications to the Spool Mapper, the next
exercise is to make the form a two-part form. Begin by pressing F1-Flash
from the Spool Mapper screen. Press F10 to go to the text screen. Make the
new entry on the text screen as shown in Figures QS-28 and QS-29). These
entries put the word Original centered on the bottom of the first page of the
Invoice.
Quick Start - 23
Integrated Custom Software, Inc.
(the positioning and centering are already done!). Your form is now a two-
part invoice form. One step remains – you need to copy the data from page
one to page two as well.
Press F12 to return to the Spool Mapper screen. Note that at the bottom of
the screen you have a Copy option. Enter the first reference to be copied,
the last reference to be copied and the reference number where you want
the new references to appear. Figure QS-32 shows the copy parameters
filled in. In our example, we are simply copying reference 1 through 5 and
placing the new references at reference line 6. Press F10 to COPY the
Quick Start - 24
FormSprint Instructions
references. Now change the OUTPUT page number to 2 (page 2 is our File
Copy) as shown in Figure QS-33.
Figure QS-28 – Add the word “ORIGINAL” to the bottom of the sample form.
Figure QS-29 – Make sure to press ENTER and center the text.
Quick Start - 25
Integrated Custom Software, Inc.
Quick Start - 26
FormSprint Instructions
Figure QS-32 – Use the Copy Ref field at the bottom of the screen to copy
the references for Page 1 to Page 2. Press F10.
Quick Start - 27
Integrated Custom Software, Inc.
Separating The Form Pages Using Distribution
The DEMOINV now has two pages (an Original and File Copy) and data has
been mapped to both pages. The final step might be to separate your pages
so that all of the originals print together followed by all of the copies together.
Press F2 from the Spool Mapper for the Printout Default Values screen. You
first entered this screen when you began your new form. You can return
here whenever there is a change to any of the default values. We are going
to change the Collate option. The default for Collate is N for No. Change this
option to D for Distribution as shown in Figure QS-34. Now press F8 to
access the Distributed Print Selections screen and make the entries as
shown in Figure QS-35.
When using distribution, an entry of *QUEUE for your printer queue tells
FormSprint to print this page at the laser printer attached to the Virtual Input
Queue as established in the Job Controller (go back to page QS-3 to see the
Batch Job Parameters screen). Alternatively, you could enter an actual
printer output queue in this field (NOT the Virtual, but the ACTUAL printer
output queue). Enter the library (*LIB if using *QUEUE, or enter the actual
library), enter the number of copies and then put an X under the page (page
1 is the Original, page 2 is the File Copy) to include. Press F12 to Return
when you are done and then ENTER to return from the Printout Default
Quick Start - 28
FormSprint Instructions
Values screen. The Distribution selections we’ve made will occur every time
this form processes. If you have a need to print a particular page of a form
based on something in the data itself, please read Chapter 6 – Distributed
Printing which explains how to use Variable Distributed Printing.
When you are all done with your form, press F24 to cancel out of the
FormSprint Editor once again. Enter the WRKOUTQ command for TESTQ
and release your spool file once more. You now have a two-part invoice with
Original and File Copy! Have fun with your DEMOINV and please do read up
on the Functions available to you with FormSprint. The Functions provide a
powerful “programming” language, which permits extensive manipulation of
the spool file.
If you have a particular form challenge, please feel free to call ICS for
advice. ICS has a staff of people who build forms all the time and they will be
happy to help you or we can arrange to custom build your forms for you.
Quick Start - 29
FormSprint Instructions
Chapter 2
Positioning and Formatting the Fixed Data
After completing the Print Default Values screen, the next screen to be
displayed is the Spool Mapper or Data Mapper screen. The layout of this
variable text-mapping screen will depend on the editor selected when
creating the form (S - for the Spool Mapper or D for the Data Mapper). Turn
to Chapter 4 for instructions on using the Spool Mapper and the Data
Mapper. Both editors use the same flash definition screens.
In most cases, when defining an entire form (fixed and variable data), the
easiest method is to begin with the fixed elements of the form, the lines,
boxes, shaded areas, fixed text, and graphics such as logos, or what we
refer to as the flash definition. Access the Flash Definition screens by
pressing F1- Flash Definition from the Spool Mapper (as shown in Figure 2-
1) or Data Mapper screen.
Figure 2-1 – Press Function Key 1 from the Spool Mapper to access the
Flash Definition.
Most users find it useful to have a copy or replica of the form handy to jot
down parameters as you go along (for example, to write down left and right
The first screen to appear is shown in Figure 2-3 and is used to define
vertical lines. Note that on all flash definition screens, the output page or
macro and screen numbers appear at the top of the screen. It is important to
note the distinction between screens and pages. ‘Page’ refers to the next
physical page of a form definition, for example, the Terms and Conditions on
the back of an Invoice form if you are doing duplex printing, or the File Copy
of a Return Authorization form - a different physical page. ‘Screen’ refers
simply to the individual data entry screens used to define a page. It may take
three or four screens to define the flash text, for example, for one physical
page of a form. Function Keys 2 and 3 allow you to scroll back and forth
from one page of the definition to another and Keys 4 and 5 allow you to
scroll back and forth from one screen to another. You can also navigate
An additional level within the flash definition is the macro. The macro or
macros may consist of a few common elements within a form (for example,
the company logo, name and address) or it could be the entire page layout.
Function Key 14 serves as a toggle between the page and the macros
(pressing F14 from a page screen takes you into a macro screen, and vice
versa). You move from macro to macro just as you would from page to page,
with Function Keys 2 and 3 or by typing in your destination page or macro.
Macros are discussed in more detail in Chapter 3.
Distance Parameters
All positioning parameters (Distance From Left, Right, Top, and Bottom)
used in FormSprint are measured in millimeters with an accuracy of two
decimal places. All distances are measured from the top of the page (or
macro) and from the left side of the page (or macro). To aid in form
definition, the program includes a clear plastic millimeter grid (each grid
square is five millimeters). Also included, is a form ruler with various scales
for pitch values and lines per inch as well as millimeters. To use the grid,
simply place it over the form aligning the upper left corner of the page at the
zero coordinates. If using the grid, simply read the millimeter values from the
grid. Because printers vary, it is useful to begin by printing a vertical line 5-
mm from the left and a horizontal line 5-mm from the top. Use these lines to
align the grid exactly for your printer (remember to delete the lines
afterward).
When duplicating or creating forms which are specifically designed for input
data to be printed at 6 or 8 lines per inch, the size of the print line must be
considered. The overlay grid may be used to determine starting positions in
this case, but the actual size of the print line in millimeters using two decimal
places will create the most accurate forms. The lines per inch scales on the
ruler may also be useful in determining how many print lines separate
different elements of the form.
To determine the size of print lines, lines per inch must be converted to
millimeters for the FormSprint flash definition screens. The calculations for
the most commonly used 6 or 8 lines per inch are as follows:
1/6 (6 lines per inch) = .1666" /print line X 25.4 (mm per inch) = 4.23 mm /
print line
1/8 (8 lines per inch)= .125"/print line X 25.4 (mm per inch) = 3.175 mm /
print line
When creating a form that was previously printed edge to edge, some
reduction may be necessary for laser printing in order not to truncate your
data. Adjustments to variable data pitch and lines per inch values can be
made to accommodate the reduced form size. In this case, it may be easier
to calculate the font specifications for your variable data (font point size,
pitch and lines per inch), set these in your print default values screen and
then print the data to a blank form. If you have enough test data, you can
then simply draw the fixed elements of the form around the data.
To calculate the correct pitch so that your data will fit on the page or within a
specified area like a box, measure the width of the area in inches and divide
the number of characters by the space available for printing, the result is the
pitch. If you wish to print the full width of the page, keep in mind that the
laser page loses about one quarter of an inch all around. For example,
suppose your spool file is a report that is 132 characters wide. We wish to
print these 132 in landscape format the full width of an 8 1/2" X 11" page.
The calculation would be as follows: 132 char / 10.5 in. = 12.6 (pitch) OR if
working in millimeters; width/number of characters = size of one character
divided into 25.4 (mm/inch) = pitch.
Now, we could select any point size that would be appropriate for this pitch
value (probably a 9 or 10 point font) and we are sure that our data will fit
exactly in the space available.
Width Parameters
All width parameters in FormSprint are measured in printer dots, with one
inch equal to 300 dots. Therefore, an entry of 300 would create a line width
of one inch, an entry of 150 would produce a line one half inch wide, and an
entry of 3 would produce a line one hundredth of an inch wide. Width
parameters are found on the screens that describe vertical and horizontal
lines and boxes. Vertical lines widen to the right so that the starting dot
position is exactly positioned by the millimeter distances entered on the
definition screen. Likewise, horizontal lines widen downward and boxes
widen inward. Some sample line widths are shown in Figure 2-4.
When designing forms that may be faxed using an integrated fax device, set
all line widths to a least 3. The fax devices do not have the full 300 X 300
DPI resolution, therefore, line widths of less than 3 dots may cause lines to
disappear altogether.
would create a light gray line that makes a satisfactory substitution for a
dotted line. A density of zero would produce no line at all, for example, to
produce a gray box with no outline. A density of 1 is used for white. Fill
density for boxes is also a percentage. A fill density of 5 would produce a
light gray filled box. Generally, it is a good idea to keep shaded boxes light,
especially if words appear in the shaded area. A fill density of 100 produces
a black box; a fill density of 1 creates a white box. Figure 2-5 shows some
sample densities.
With printers that support PCL5, reverse (white) lines and boxes can be
created by using a density of one. This causes the line or box to replace any
underlying print. For example, to produce a white box within a shaded box,
the parameters shown in Figure 2-6 could be used. Likewise, lines defined
with a density of 1 would produce white lines against either a black or
shaded area.
A density between 100 and 0 will not replace underlying print (you can see
through it). However, a density of 1 will replace underlying print as described
above. Therefore, a box with a fill density of 1 can be used on top of another
THIS IS SOME
TEXT IN A
BOX.
Figure 2-6 – A box with a fill density of 1 will cover data that is
positioned below it.
THIS IS SOME
TEXT IN A
BOX.
box as in the example shown in Figure 2-6. Or, if the white box is in a macro,
it could be used to conditionally block data on a form (see Chapter 5 for
more information on this technique under Substitution Table).
Color Support
When using printers that support PCL5C (such as the HP1200C), color
printing is supported through FormSprint. A color palette is defined through
the administrative functions of FormSprint (please refer to Chapter 17). The
color palette equates numbers with specific colors. To invoke a specific color
in a form definition, the density parameters are expanded to the left. For
example, if you wanted to create a green line, and if green is color 3 on the
color palette, you would expand the three-digit density parameter (100) by
adding a 3 to the left to produce a color-density of 3100 (see Figure 2-7). To
fill a box with a 20 percent shading in red (if red is defined a color 2 in your
palette), you would expand the fill density parameter - 020 by adding 2 to the
left to produce 2020 for the color/fill density. Note that when using density
parameters for lines and boxes when you are also using color, the density
Figure 2-7 – Add color to line by expanding the density field to include a
color – in this case, color 3.
The Flash definition includes all of the fixed elements of the form (the lines,
boxes, fixed text and graphics). The order in which you move from element
to element is entirely up to the form designer. However, a logical progression
from the larger elements to the smaller, from top to bottom and from left to
right will most likely create a form design that will be easier to modify at
some future time. At any time in the design process, you can stop and print
the form by pressing F15 - Print followed by ENTER (Figure 2-8). The
printout will include all elements on the one page or macro you are working.
All screens for lines, boxes and graphics permit inserting a line with F17 and
deleting a line with F18. Insertion and deletion of text lines should be done
from the expanded text screen.
Figure 2-8 – Access the Flash Printout screen by pressing F15 anywhere
within the Flash Definition.
The density value indicates the percent shading of the line. Entering 100
produces a black line, while entering a value of 5 or 10 would produce a gray
line that could be used as an acceptable substitution for a dotted line. An
entry of 0 (0%) will result in FormSprint discarding the line altogether.
Using a density of one (this is only supported on PCL5 printers) can produce
white lines. The example shown in Figure 2-10 defines the vertical lines
separating the columns on an invoice form. The lines are defined in pairs.
The first entry in the pair defines the white lines on a black header box, and
the second entry in the pair defines the black line on the white box.
Multiple evenly spaced lines can be produced with a single entry by entering
values in the Number and Spacing columns. The spacing value is the
distance between the lines in millimeters, or the distance from left edge to
left edge. When using very wide lines, you may need to consider the line
width when calculating the spacing. In our example (Figure 2-9), the single
entry on the Vertical Lines screen will produce two identical vertical lines
spaced 50 millimeters apart.
Next, enter the Density value for the line. Density is also the same as that
described for vertical and horizontal lines, and represents a percentage of
density. An entry of 100 produces a black outline, an entry of 5 would
produce a gray line, and an entry of 0 would result in no outline at all.
Entering a fill density can shade boxes. Entering 100 would create a solid
black box, while entering 0 will leave the box empty. A fill density of 1 is
white. Note that a fill density of 0-zero is not the same as 1-white. A density
of zero does not cover data behind the box, whereas a fill density of 1 will
obscure data behind. Entries between will create shades of gray. Figure 2-5
shows some examples of these fill densities. Generally, boxes which will
also include text should have very light fill densities to make the text more
readable (a fill density of 10 works well with most text).
In the example shown in Figure 2-12, the first line of entries create a box
with a left edge 130 mm from the paper’s edge, a right edge at 200 mm,
beginning 55 mm from the top of the page and with a bottom at 80.4 mm.
The box has an outline 3 dots wide and is not filled.
Entering a value in the Number column and then entering the horizontal or
vertical Spacing between the boxes can produce multiple evenly spaced
boxes. Spacing is in millimeters and is the distance between equivalent
positions, i.e. start to start. For example, entering 10 for the horizontal
spacing would start the left edge of the second box 10 millimeters to the right
of the left edge of the first box (see Figure 2-13).
The second line in our example pictured in Figure 2-12, defines two boxes,
each 70 mm wide and 4 mm high with a vertical spacing of 12.7 mm
(because spacing is equal to the distance from start to start, the spacing
between the boxes = 8.7 mm). The last line in the example creates a series
of boxes (19 boxes in all) vertically spaced by 8.46 mm or 2 print lines at 6
lines per inch. This final entry produces the "comb" effect used on many
forms to highlight every other print line.
Note that while boxes can be produced by using horizontal and vertical lines,
if the line width is greater than 1, the corners will not close properly, while
the box commands produce perfect box corners. Rounded corner boxes can
be created by entering HP GL coding as discussed in Chapter 12 or by
uploading a PCL file from a PC draw package.
Color is defined for boxes as it is for lines, through the expansion of the
density and fill density fields. Remember that when using color, the density
parameters must be three-digit numbers even if the first digit is a zero, for
example, a fill color/density of 3030 would use color 3 - density of 030 =
30%.
Fixed Text - Fixed text is entered into the flash definition by pressing F10 =
Text, producing the screen shown in Figure 2-14. This screen is used for
entering the fixed text for the form. Entries made on this screen will appear
on the form exactly as you type them. If, for example, column headings
should be all caps, then they should be entered in this screen in all caps.
Following the text entry itself, are precise positioning parameters and
parameters which select the face and style of type to be used. Positioning
parameters include the distance from the top of the page (in millimeters) and
the distance from the left of the page (also in millimeters). These parameters
describe the position of the bottom left edge of the first letter of the text line
as shown in Figure 2-15.
The font number parameter consists of a typeface code, size, style, and
weight. FormSprint uses the printer’s resident fonts and also supports some
cartridge fonts as well as some specialized soft fonts (i.e. MICR, OCR-A & B
Figure 2-14 – The Flash Text screen – press F16 for a list of fonts and
symbol set selections.
and custom soft fonts). The number of fonts that can be used on a single
form is limited only by the printer capability.
INVOICE
Figure 2-15 – Text is positioned to the bottom of the letters. The default
format will always be left justification.
The font number is in the form AABBC where AA is a one or more digit
number representing the typeface - for example, 4148=Univers. These
numbers are defined for each printer or for each font cartridge. The fonts
listed in Appendix D of this book are the HP internal scalable fonts. At least
some of these fonts are widely available on most PCL5 printers, please
check your printer documentation for availability of fonts. BB represents the
point size (the height of the letter) - if you are using a scalable font, you may
For most form applications, a selection of Univers or CG Times for all fixed
text entries will produce a good readable form. A fixed pitch font is generally
selected for variable text. Also, in most cases the Roman 8 symbol set will
give all characters needed including most of the French and Spanish
accented characters. The Legal symbol set includes the copyright,
trademark, and registered characters.
A listing of supported fonts can be accessed with Function Key 16 from the
Text Definition screen and is also listed at the back of this book and in
Chapter 13. The numbers listed for the font cartridges represent the
complete number; typeface, point size and symbol set selector. The font
Weight for these fonts controls the boldness of the type. For the scalable
fonts, the Weight should be as specified for the particular font numbers as
shown on the listing in Appendix D. For cartridge fonts, a weight of 1 will
result in regular weight and 2 will produce a bold font.
The Weight field is also used for color support and for reverse or shaded
text. As with lines and boxes, for colored text, the weight/density value is
expanded to the left. To produce, for example, green text (color 3) with a
weight of bold (density 4), the weight parameter would be 34.
The Expanded Text Screen is used when you have more than a single line
of text or if the entry does not fit in the space provided on the first text
screen. This screen is also used if you wish to use FormSprint’s special
text formatting features (centering, setting text flush left or right, justifying or
rotating text with a PCL5 printer). Access this screen by typing as far as you
can on the first text screen, fill in the parameters, then position the cursor in
any field on the text line and press ENTER. You will then be provided with a
free form multi-line text screen, as shown in Figure 2-17. Begin by
completing the parameters at the top of the screen. Enter a right margin
position (in millimeters), the lines per inch, and select flush left, right,
centered or justified for formatting. You may also change the pitch value for
your font. This may be particularly helpful if you are using a fixed pitch font
and wish to set the pitch value such that each letter or group of letters
precisely fits a space or column heading. A final parameter may be used to
rotate fixed text.
If you are using a PCL 5 printer, text can be rotated in 90-degree increments
counterclockwise relative to the basic portrait or landscape orientation of the
page. Entries of 90 (landscape), 180 (upside down), and 270 (reverse
landscape) are acceptable for this parameter. As shown in the Expanded
Text screen in Figure 2-18, enter the degree of rotation in the Rotation
parameter field in the upper right-hand corner.
Figure 2-17 – The Multi-line text screen is used for entering multiple lines of
similar text – like a column of words or numbers.
19. If you are using the grid overlay, simply rotate the grid counterclockwise
in 90-degree increments to establish the rotated coordinate system.
Rotation may be used to rotate all text on a particular form in order to have a
page in a different orientation from the rest of the form.
Word Wrapping - The Expanded Text screen is also used for entering
multiple line text either with or without automatic word wrapping. After
pressing ENTER anywhere on the text line, continue by filling in the top of
the screen (right edge, lines per inch, pitch if appropriate, format, and/or
rotation) continue typing where you left off on the first text screen. The line
insert and delete functions (F17 and F18) can be used to aid modifications.
At the end of a paragraph or at the end of any entry that extends past one
line on the text entry screen, use F20 to wrap the text. Before using F20,
make sure that you have left a blank line between paragraphs or indented
the first line of each paragraph by two spaces (Figure 2-20), or the program
will wrap all of the text together. The print routine will automatically join and
wrap your text to fill the width prescribed by the left and right margin
parameters. Note, however, that the screen will not wrap in the same way as
your output. Up to ten screens can be entered for each text entry.
Figure 2-19 – When rotated text is positioned, the distance from the Top or
Left will be measured from the rotated co-ordinate system.
Figure 2-20 – The Expanded Text screen is also used to enter paragraph
text with automatic text wrapping if required.
Inserting Text – The first screen of Form Flash Text does not permit line
insertion. When entering your text, it is wise to leave blank lines between
entries so that text may be added at a later date in the logical order in which
they appear on the form. The order that you use in entering text is irrelevant
to FormSprint, however, for ease of maintenance entries should be in a
logical order. To insert text within a text entry, press ENTER to go to the
Expanded Text screen. The Expanded Text screen permits Insertion with
F17. Place the cursor on the line before your insertion and press F17. Next,
type the additional text and finish with F20 to wrap the text together.
Deleting Text - Use the Delete Line function (F18) of the Expanded Text
screen to delete text. You will note that the first text screen does not allow
deletion. To delete any text, press ENTER on the text line and then position
the cursor within the first line to be deleted and press F18 to delete the line.
Deleting in this way is preferable to simply using the Field Exit because all
text parameters including distances, font and formatting are deleted at the
same time.
Centering Text - The free form multi-line screen can also be used to select
special formatting such as centering text within a box, column, or page. In
order to center text, you need to define left and right limits within which you
wish the text to be centered.
The left limit is the From Left parameter from the first text screen. This
parameter could be the left side of the page, the left column position if you
are centering over a column of data or the left side of a box if you are
centering within a box. In our example in Figures 2-21 and 2-22, the words
INVOICE NUMBER are centered over a column beginning at 0 millimeters
from the left of the macro. The right parameter is entered at the top of the
multi-line screen and is the right side of the macro/page, right side of the
column, or the right side of the box. In our example, the column is 30
millimeters wide with the right side at 30 millimeters. Entering a ‘CN’ for
Format tells the program to center the text within the limits you have
specified and suppress word wrapping. Using the centering function means
that even if the text changes at some time in the future, the new text will still
be centered without changing the positioning parameters.
Figure 2-21 – To center text, enter the Top, Left and the Font and Weight
and press ENTER.
When you have finished using the Expanded Text screen, press ENTER to
return to the main text entry screen.
Barcodes can be produced in a form’s flash definition from the fixed text
screen. The font characteristics are used to specify the barcode type and
specifications. For information on the specific bar code types, please refer to
Chapter 4.
For example, to produce a 3-in-9 barcode (Type 101) with bars 12 mm high
and a narrow bar width of 4 dots, the font value would be 101120 and the
weight would be 4.
Entering 109100 with a weight of 1 in the font specification field creates the
Postal Code. To obtain the Reverse Postal code, enter 115100 with a weight
Multi-line text screens can be used for barcodes. Care must be taken to set
the right margin wide enough to support the barcode width and prevent word
wrapping.
Graphics
The graphic file name is entered in the first column of the Graphics screen.
To prompt for the graphic files, place the cursor in the file field and press F9.
Select the desired graphic by placing your cursor under the file and press
ENTER. Function Key 12 returns to the flash screen without selecting a
Figure 2-23b – To select a graphic, place the cursor on the File Name field
and press F9. Place the cursor on the desired graphic and press ENTER.
graphic file. Next, the location of the upper left corner is entered in columns
2 and 3, the Vertical and Horizontal Locations.
If your printer supports true 600 DPI graphics, enter 6 for scaling and PC600
for the printer driver for 600 DPI output. However, if the graphic has been
scanned at 300 DPI and is then printed at 600 DPI, the resulting image
would be one half size. To print the 600 DPI image at full size, the graphic
should also be scanned at 600 DPI.
When using PCL5 printers or PCL5C color printers, the scaling parameter
can also be expanded to create colored, shaded, or reverse (white on black
or a shaded area) graphics. Shaded graphics are achieved by expanding
the scaling parameter to the left and adding a percent of shading. For
example, to produce a graphic that is shaded 80 percent, the scaling
parameter would be expanded to 801. To produce an enlarged ‘watermark’
The last three columns of the Graphics definition screen allow you to repeat
a graphic. Enter the number of images desired in the Number column, and
then enter the horizontal or vertical spacing depending on whether you want
the graphic repeated horizontally or vertically. As with repeated boxes,
spacing is the distance between equivalent positions of the graphic. The
sample shown in Figure 2-24 is used in the set up of a sheet of 10 2" X 4"
labels. The first image is defined for each vertical column, and then repeated
5 times for each column.
Entering the macro number in the graphic file name field can place macros.
The example shown in Figure 2-24 uses macros to define each of our labels;
the macro is then copied to create our 10 to a page example. The macro
number is the system assigned number displayed at the top of the screen
when defining the macro (in the same position you would see the page
number).
Multiple part forms with similar or copied pages can be easily defined using
F13=Multipart Page Copy/Delete accessible from any of the flash definition
screens. This produces the screen shown in Figure 2-25. You can copy a
page or macro from within the same form, or from any other form to which
you have COPY access. Select the input page, the output page, and if you
are copying from another form, press F1 to access the list of available forms
and press ENTER on the form you wish to copy. The multi-page copy screen
will display the name of the form from which the page or macro will be
copied. Press ENTER to complete the copy. You will need to access the
Multi-Part Page Copy screen once for each page and/or macro being
copied. If you access the Multi-Part Page Copy screen multiple times, the
program will recall the form from which you copied the previous time. If you
are working on a multi-part form (for example, an invoice with Original and
File Copy pages), remember that the Multi-part page copy function only
copies your flash pages, not your variable data.
Figure 2-25 – The Multi-Part Page Copy and Delete screen. Access this
screen with F13 for copying or deleting a page or macro.
The Multi-Part Page Copy/Delete screen can also be used to delete any
page of a flash definition or any associated macros. Simply put the page
number of the page to be deleted in the space provided and press
F8=Delete. The system will return a message at the bottom of the screen
telling you that the page or macro is deleted, press F12 to Return to the flash
definition.
When you have completed the form flash definition, use either F12=Return
to return to the Spool Mapper or Data Mapper to define the positioning of
variable text, or F24=First Menu to return to the Editor Main Menu (Figure 1-
1).
Chapter 3 – Macros
Macros are flash pages that can be used like graphics. Macros are defined
in the same manner as fixed form flash pages but can be used anywhere a
scanned graphic could be used. Macros can be called from a flash page
graphic screen or used as imbedded graphics from an input spool file,
intermediary file, or from direct data entry. Macros can also be called
dynamically by using conditional logic and the buffers through the Spool
Mapper screen (see Chapter 4 for more on using FormSprint’s buffers).
Macros are defined as part of a form’s flash definition. Access the macro
designer by pressing F14=Macros/Pages from any of the screens in the form
flash definition. F14 will toggle back and forth between the macro design and
the page design. The program will display the macro number and screen
number at the top of each screen when in macro-mode just as it displays
page number and screen when in page mode. The screen shown in Figure
3-1 is the first text definition screen for macro one (note on the top of the
screen - TEXT - Macro 1-1).
Macros 3-1
Integrated Custom Software, Inc.
Function keys 2 and 3 scroll back and forth from macro to macro just as
function keys 2 and 3 scroll back and forth from page to page when in page
mode or you can simply type the destination macro number and screen
number at the top of the screen. You can define up to 100 pages and 100
macros in any form, providing sufficient memory is available in the printer to
hold the macro definitions during printing.
Macros can contain any or all of the elements of a flash page, including text,
graphics, lines, boxes, and shading. The Multi-page Copy/Delete function
(F13 - from the flash definition screens) will copy or delete a macro in the
same manner as pages. Flash pages can be copied to macros and macros
to flash pages. Macros are identified by their macro number (as displayed at
the top of the screen – for example, M1 or M2). When using the Multi-part
Page Copy/Delete function or when entering a macro on the graphics
screen, identify the macro by entering M plus the system-assigned number
(i.e. M1 or M2). The example shown in Figure 3-2 copies macro one (M1) to
page one.
Macros must be defined within each form definition that will use them.
However, if there are common macros that will be used by many forms, a
template form definition could be defined that would contain each of the
common macros. Then, each time a new form is built, the template form
could be copied to produce the new form. For example, your company logo
plus the address and phone numbers may appear in the same format on the
top of all of your forms. Create a macro in a ‘template’ form with the logo
Macros 3-2
FormSprint Instructions
plus the text for address information. Then, when you are creating a new
form, simply use the Multi-part Page Copy function (F13) and import the
macro for the logo/address and place it as if it were a graphic on your new
form. It is important to note, however, that if the ‘template logo’ is changed,
the changes you make in the template do not apply to all forms using the
template. You would need to go into each form and copy the changed macro
into the forms again.
Macros are placed on the form either from the flash graphics screen or from
the variable data stream. In either case, the actual print location of the macro
is the sum of the positioning parameters in the flash graphics screen (if used
in the flash definition) or the positioning parameters of the variable data
PLUS the positioning parameters of the macro itself. For example, the macro
in Figure 3-3 is a logo plus a Company Name and a two-line address. The
upper left-hand corner of the logo is defined in the macro at 10mm vertical
and 10mm horizontal. Figure 3-4 shows the flash graphics screen
positioning the macro at 20mm vertical and 20mm horizontal and the
resulting actual placement of the macro at 30mm vertical and 30mm
horizontal.
Figure 3-3a – The sample macro contains a logo plus the text for the name
and address.
To print just the macro, press F15=Print from any of the definition screens
(just as you would for a form flash page). The program will automatically add
4 millimeters to both the vertical and horizontal position for this printout (this
is to accommodate the requirement of the laser printer to position no closer
Macros 3-3
Integrated Custom Software, Inc.
than 4mm to the edge of the page). Therefore, if your macro is defined to
begin at 0 from the top and 0 left, your printout will be positioned at 4mm
from the top and 4mm from the left.
Figure 3-3b – The positioning of the graphic file in our sample macro.
The macro could be the entire form flash definition or it could be just one of
the elements of the flash page. For example, an AP check form has two
major elements: the statement portion and the check itself. Each of these
two logical sections of the form could be defined as separate macros (see
Figure 3-6). Then, the two macros would be entered on the Flash Graphics
screen as shown in Figure 3-7, M1 for the statement and M2 for the check
portion. The macro for the company name and address would then be added
to the Graphics screen shown above, to place the company name and
address once on the statement and then on the check itself. The final form is
shown in Figure 3-8.
Often, we require a file copy of the accounts payable check. However, the
file copy should not have the MICR line and should not have a signature and
perhaps it should have the words ‘NON-NEGOTIABLE COPY’ printed
across the check portion. The use of macros permits us to copy M2 to M3
(using Multi-part Page Copy – F13) and then we would go to macro 3,
replace the text for the MICR line with the NON-NEGOTIABLE message and
remove the graphic for a signature. Now, when we define flash page 2 for
Macros 3-4
FormSprint Instructions
the file copy, we simply use M1 (the stub) plus M3 for the new non-
negotiable ‘check’ portion.
Figure 3-4b – If the leftmost side and the top of the macro have been defined
to start at 10mm, as in our example, and then the macro is placed at 20mm
vertical and horizontal, the end result is that the macro is 30mm from the top
and left.
Macros 3-5
Integrated Custom Software, Inc.
Figure 3-5 – When the elements of the macro are defined to start from 0, it
becomes easier to place the macro exactly where you want it on the page.
Figure 3-6 – Defining the logical areas of the form can simplify the design
process.
Macros 3-6
FormSprint Instructions
Figure 3-7 – After the macros have been designed, they can be placed on
the page on the Graphics screen.
Figure 3-8 – The final check form puts the check and stub macros together.
A third macro could be added for the company logo to be placed twice, once
on the stub and once on the check.
Macros 3-7
Integrated Custom Software, Inc.
Defining the logical elements of the form flash definition as separate macros
can sometimes greatly simplify the definition process. Also, this technique
enables you to move whole sections of the flash definition as easily as
changing the vertical and horizontal position of the macro when placing it on
the Flash Page Graphics screen. This technique also enables you to repeat
a form element with a one-line entry in the graphic page definition, as shown
in Figure 3-9.
Figure 3-9 – Multiple macros can be placed by using the Number and
Spacing fields on the Graphics screen. This example could create a sheet of
name and address labels as shown below.
Macros 3-8
FormSprint Instructions
Using Macros in the Variable Data Stream
Macros can be called from the variable data stream in the same manner as
graphics are called. Enter the coding &% followed by the macro name - for
example, &%M1. This coding could be at a set location, for example Line 3
Position 1, or it could be placed anywhere within the print stream. The
sample spool file shown in Figure 3-10 has several imbedded macro calls.
The macro entered from the variable will be positioned just as text would be
if it were at the same location in the print stream. However, the actual
placement of the top of the macro will be the definition coordinate of the top
of the macro (usually 0) plus the distance from top as defined for the
variable.
Figure 3-10 – This sample spool file contains imbedded macro calls.
For example, suppose our sample check is to be used for various divisions
of our company. The basic check design is the same for all divisions, the
only difference being the company/division name, address and logo. We
would define a macro within the check form for each of the divisions. The
macro definitions would be similar to the one in our example in Figure 3-3,
with the coordinates of the upper left-hand corner at 0,0. Then, we would call
the division macros from the variable according to which division we were
processing. Suppose that we always placed the macro in Line 2, position 1
of the spool file. We could then use the Spool Mapper to select Line 2,
columns 1-4 and position our macro at 10mm from the top and 10mm from
the left to place the macro on the statement part of the check. The actual
placement of the top of the macro would be at exactly 10mm from the top
Macros 3-9
Integrated Custom Software, Inc.
and 10mm from the left. Then, we could refer to the same line and columns,
and this time position the macro at 200mm from the top and 10mm from the
left to place the macro on the check itself. Figure 3-11 illustrates this use of
the macros.
Macros can also be called from a Substitution Table based on some data
within the spool file. For example, a company number or store number could
be the ‘key value’ within a substitution table that would return a call for the
macro that is appropriate for that store or company. Please see Chapter 5
for a discussion of the Substitution Table.
When called from the variable data stream, macros permit the user to create
a completely dynamic form based on the content of the print stream itself.
For example, suppose your form is a report that has varying numbers of
sections, each with a varying format and varying lengths. Separate macros
would be defined for each of the different headings that could occur within
the report. An example of such a heading is shown in Figure 3-12.
Macros 3-10
FormSprint Instructions
Figure 3-11b – This spool file contains a macro call in a fixed position – line
2 columns 1 through 4.
Figure 3-12 – In this example, various macros are designed and called
dynamically to create the form “on the fly” based on the data.
Figure 3-13 – This might be the macro that continues the sides of the boxes
in a dynamic form definition.
added to the report. In order to close the lines and facilitate the positioning of
the data relative to the macro, the macro can be defined to have a distance
from the top at a negative position (for example, -1mm). The actual print
position is the sum of the position of the macro plus the position of the
variable. Therefore, a macro starting at -1mm from the top and positioned in
Macros 3-11
Integrated Custom Software, Inc.
the variable at 10mm from the top would actually be positioned at 9mm from
the top.
Another macro could be defined which would close the bottom of the
columns being built by the continuation macros. This macro would be called
when the final detail line was added to the report, as in Figure 3-14. Figure
3-15 shows how the completed form with data might appear.
Figure 3-14 – The final macro call would complete the bottom of the box.
The above technique requires the programmer to modify the program to call
the macros at the appropriate locations within the spool file. FormSprint’s
special functions would permit the user to accomplish the same effects
without making programming changes. For example, let’s take the example
of a report containing multiple parts with varying headings and of variable
lengths. In order to make the report more readable, we would like to modify
the headings so that they are boxed and shaded with text that is bold and
stands out from the rest of the report. The first step would be to identify the
wording or character string that is unique about each of the headings (see
Macros 3-12
FormSprint Instructions
Figure 3-16). The next step would be to ‘test’ the report data using Print If or
Don’t Print If logic and return to a buffer a call for the appropriate macro.
Next, the report data is simply printed to the output page. Finally, the buffers
are read and printed and wherever a match was made using the Print If
/Don’t Print If logic, the appropriate macro will be printed. Figures 3-17 and
3-18 show the coding for this report. Note that if you are replacing a heading
with different fonts or wording, the macro must contain a white box to ‘cover’
data below. A shaded box and text can be added on top of the white box.
Figures 3-19 and 3-20 show the macro flash definition for a sample heading.
Figure 3-16 – We can use unique wording in the spool file to identify the
beginning of a heading for the placement of the macro. For example,
“Component Description” might trigger the placement of a heading macro.
Macros 3-13
Integrated Custom Software, Inc.
Figure 3-17 – The Spool Mapper contains a reference to identify each of the
unique headings.
Figure 3-18 – We use the “Print If” function to identify the unique words in
the spool file that trigger a heading. If the Print If has a match, a call for the
Macros 3-14
FormSprint Instructions
macro (&%M2) is placed in the buffers. After all headings have been
identified, the macros are printed from the buffers (see reference 11 above).
Figure 3-19– The box screen for the heading macro. A negative is used for
the top of the box to “pull” the heading up and over the variable data.
Macros 3-15
Integrated Custom Software, Inc.
Macros 3-16
FormSprint Instructions
FormSprint form designs can receive variable data from direct data entry
screens created by FormSprint, from flat data files comprising formatted,
sequential data fields, mapped to a specific form, and from spool print files.
Application program generated spool files may or may not be formatted
exactly like the desired output. Fields may be moved, copied, reformatted,
bar coded or suppressed depending on the desired results.
The Spool Mapper permits the user to select any line or lines, column or
columns and output them anywhere on the printed form. Each field can have
a unique font (typeface, point size, pitch, lines per inch, format), can be
printed as a bar code, can utilize the extensive list of special functions, or
can be output to a buffer for further processing such as concatenation.
In many cases, the variable definition will be done after the flash (fixed part
of the form) has been defined. However, another way to approach the form
definition process, is to define the print specs (i.e.. typeface, pitch, and lines
per inch), enter one line in the variable definition as in the example in Figure
4-1, and then merge the data with this blank form. If the spool file you use is
a good representative (has examples in all or most data fields) you can then
simply draw the form around the data. This method may be particularly
helpful when there is no need for data manipulation such as mapping data
fields to new areas of the form, but where data compression is necessary to
fit the data on the laser form.
To make it fit.
There are many times when you need to calculate a pitch value that will let
you print a number of characters in a given space. This calculation is done
by measuring the space available in inches and dividing this number into the
number of characters to be printed (characters/inches = pitch). If you prefer
to work in millimeters, divide the number of millimeters in the space by 25.4
(mm/inch) to convert to inches. The maximum printable area left to right
for portrait 8 1/2" X 11" is 8 inches (or 203 mm). The maximum
printable area left to right for landscape 8 1/2" X 11" is 10.5 inches (or,
269mm).
Figure 4-1 – A simple Spool Mapper screen, placing all of the data in one
reference step.
The example in Figure 4-2 shows a piece of a sample spool file for an AP
check. The spool file at 85 characters wide is too wide for the standard 10
characters per inch printing. Calculations are made for the proper pitch value
and these are entered on the print default values screen. The printable area
of a standard 8 1/2" by 11" sheet of paper is approximately 8 inches. Simply
divide 84 (the number of characters in the spool file) by 8 to calculate the
number of characters per inch (pitch) required. Enter this value (10.6) on the
Print Default Values screen as shown in Figure 4-3. Next, the data is printed
to the blank form. The last step is the drawing of the form around the data.
This calculation for pitch can be used for any number of characters and any
space.
If the flash definition is completed first, it will be helpful to have a hard copy
of the printed form with significant measurements marked on the hard copy
before beginning the variable definition. Also essential before beginning, is
to have a clear understanding of the spool file. The SPOOL GRID will be
particularly helpful in defining start and end columns and lines within the
spool file (please refer to Chapter 18 for instructions on printing a SPOOL
GRID). A word of caution, in defining fields (start/end columns) and what
lines to utilize, keep in mind the maximum size of fields and maximum
number of detail lines to eliminate the possibility of truncating data.
Figure 4-2 – This screen shows a part of a spool file for an AP check. This
typical spool file is 85 characters wide. Without any change to the pitch, this
file would be truncated at 10 characters per inch in the portrait orientation.
Figure 4-3 – The pitch can easily be adjusted using the Print Default Values.
The Spool Mapper consists of two screens. The first screen is used for
entering line and column selections and output positioning parameters. The
second screen is used for making font changes, entering bar code
information; selecting special functions, and entering buffer information.
The name of your form is displayed in the center top of the first Spool
Mapper screen. This screen is divided into two parts, the INPUT and the
OUTPUT (Figure 4-4). Each line on the Spool Mapper is numbered with a
column heading ‘Ref’ – this is the reference number and is merely a step
number.
Figure 4-4 – The Spool Mapper. The columns on the Left describe the
INPUT data (the spool data) and the columns on the right define the
OUTPUT data positioning in millimeters.
Function keys 4 and 5 scroll to the Next (F5) or Previous (F4) Spool Mapper
screens. Function Keys 17 and 18 provide insert (F17) and delete (F18) line
capability. Position the cursor on the line prior to insertion when using F17.
Position the cursor on the line to delete when using F18.
Function Key 10 provides a block copy function. This feature permits you to
exactly copy one or more reference lines either to another place on the
output page or to subsequent pages of the form. Enter the first reference to
be copied following ‘Copy Ref____’, enter the ending reference to be copied
following ‘through _____’, enter the destination reference number in ‘to Ref
_____’. You can also enter a ‘Step Top’ or ‘Step Left’ value to increment the
‘From Top’ or ‘From Left’ positions of the new references.
Examples
The Simple Overlay
The screen shown in Figure 4-5 shows the first screen of the Spool Mapper -
Variable Text Locations. This first example places data for a 1099
Miscellaneous Income Tax form. This example illustrates the simplest use of
the Mapper - the spool file data is properly formatted in the spool file itself,
and simply overlays the form without any manipulation at all. In this case, the
form designer has simply designated the entire 66 lines of the spool file,
from column seven (no need to include the 7 leading spaces in the spool file)
through 80 and specified a starting millimeter location on the output form
(11.5 mm from the top and 11 mm from the left) - the spool data simply
overlays the form.
The second example illustrates the use of the Spool Mapper to totally
change the format of the spool data with no program changes whatsoever.
Figure 4-6 is a W2 4-up laser format. The spool file in this example was
designed for 2-up printing and is shown in Figure 4-7a. Because the spool
file was designed for a different format, this form requires mapping each field
on the form separately. The corresponding Spool Mapper is shown in Figure
4-7b. In this example, the Description column is used to designate each
item of the W2 form as it is mapped. The next five columns (Page, First
Line/Last Line, Start Column/End Column) refer to the INPUT spool file
page, line and column. The next four columns refer to the placement of the
data on the OUTPUT page. The page column is the form page. The
Figure 4-5 - When the spool file data is formatted just the way you want the
form printed, the Spool Mapper simply overlays the data on the form.
Note that it is not necessary to select input data in a sequential manner from
the spool file, rather, the logical order of the output can be used. In the
example, Item e (the employee name and address) come from lines 16-20
and are placed before Boxes 1 and 2 which come from line 6. The logical
order of the form is followed rather than the sequential order of the spool
data.
This example uses four pages of INPUT from the spool file and OUTPUTS
them to two form pages. As illustrated by the example shown in Figures 4-8
and 4-9, page one through four of the spool file are entered on the INPUT
side of the Spool Mapper screen. Page one is OUTPUT to the right side of
form page one and page two from the spool file is OUTPUT to the left of
form page two. Page three from the spool file is OUTPUT to the right of form
page two, and finally, page four from the spool file is OUTPUT to the left of
form page one. This format could be used to produce report cards or any
two page folios.
The simplest type of multi-page form is the form in which subsequent pages
are simply copies of the original, with perhaps the words ‘FILE COPY’ or
‘ACCOUNTING COPY’ rather than ‘ORIGINAL’ designating the use or
destination of the copied page.
To begin this type of multiple page form, use the Multi-Part Page Copy
function in the Flash Definition (see Chapter 2) to create multiple flash
pages, making any unique page adjustments as may be needed. Then, after
completing the Spool Mapper for placing data on page one of the form, go to
the bottom of the Spool Mapper screen and in the Copy Ref field enter the
start and end reference numbers to be copied.
Figure 4-7a – This screen shows the data for a W2 form – but it is formatted
to fit a 2-Up and not a 4-Up format.
Figure 4-7b – This screen shows the beginning of the mapping for the re-
formatted W2 form. Note that we take each field separately.
Figure 4-8 – The folio format is created by taking four input pages and
printing them to two output pages – the front and the back.
Enter the To Ref field to tell FormSprint where to begin the new reference
numbers and press F10=Copy Ref to activate the copy. The next step is to
change the page numbers to the new OUTPUT form page number. The
example shown in Figure 4-10 is a simple two-part invoice where the
Original and File copies are identical.
The number of INPUT spool pages does not have to equal the number of
OUTPUT form pages. Therefore, you might INPUT three spool pages and
OUTPUT only one form page - or vice versa, you might INPUT one spool
page and OUTPUT three form pages. The processing and formatting you
select for your multiple output pages may be the same or entirely different
from one page to the next. This function may eliminate some need for form
Tiling (see Chapter 1), however, if the Tiles are identical (such as with 1099
forms or labels) tiling will be more efficient.
Figure 4-11 – A sample two-part invoice where page one is NOT identical to
page two. The second part of the invoice might be a Packing Slip where you
might not want pricing information to appear. Note reference 7 is different
from reference number 2.
The order in which you output data to your form pages does not have to be
sequential. Therefore, you could input data from page two of the spool file
and output to page two of the form, then follow with input from page four of
the spool file and output to page one of the form. Any buffer processing is
completed before any other reference processing. Therefore, you could not
enter data to a buffer, use it on one reference and then change the buffer
data in some way for another step in your processing. Also, the output
positions on the form page do not have to be in order from top to bottom. For
example, you could output the check number for a check form to the three
places you want the number (stub, check and MICR line) as the first steps
on your Spool Mapper and then go on to position the rest of the stub and the
rest of the check.
The second Spool Mapper screen is the Fonts and Functions screen (Figure
4-12), and is accessed by pressing ENTER anywhere within the definition
line. The reference number and definition will be displayed in the center of
the Fonts and Functions screen. If no special processing is being done,
there is no need to access this screen.
The Fonts and Functions screen can be used to change fonts (the list of
fonts is available by pressing F1=Fonts), print parameters such as weight,
lines per inch, pitch, formatting, rotation. All lines selected on the input side
of the Spool Mapper will be adjusted for the weight, lines per inch and/or
pitch regardless of the values entered on the Print Default Values screen. If
no change is made to the format parameter, text will be left justified.
However, you may select right justification, centering, and word wrap or text
justification. Right justification uses the Output Right Edge value for
justification. Centering uses the Left and Right Edge values entered on the
Output side of the Spool Mapper for centering. When using word wrap or
justification, all lines within the range of selected input lines will be wrapped
between the left and right margins specified for the output parameters.
Paragraph breaks are processed when either a blank line or an indented line
is encountered.
The Fonts and Functions screen is also used to create bar codes. Enter the
Input line or lines and start and end columns of the fields to be bar coded on
the Spool Mapper screen. Next, press ENTER for the Fonts and Functions
screen. Enter the height and minimum bar width (this is the nominal bar
element, or the width of the narrowest bar or space) and mark the desired
bar code with a letter ‘X’. The smallest value that can be entered for the
Figure 4-13 – The Fonts and Functions screen is used to define bar codes.
Enter a bar height and width and mark the desired type of bar code with an
“X”.
Codabar – Codabar employs numeric characters only (except for the Start
and Stop codes, which are lowercase a, b, c or d) plus the minus sign, dollar
sign, colon, slash, period and plus sign. Codabar can be of variable length
(up to 32 characters). Codabar allows bi-directional scanning. No check digit
is used with Codabar.
Postal Barcodes – The specifications for postal code and the reverse postal
code are set by postal regulations. Therefore, no entry is made for the height
and minimum bar width for these selections.
Plessey and Modified Plessey – The basic Plessey code supports only the
numerals 0 through 9 and the upper case letters A through Z. No error
Special Functions
FormSprint’s special functions are also entered on the Fonts and Functions
screen following the bar code selections. Please refer to Chapter 5 for
descriptions of the various functions.
Buffer Loading
Any line or lines, column or columns from the spool file can be output to
FormSprint’s buffers. The buffers are work areas that allow you to perform
one or more functions and/or add other data to the data in your buffer work
area. A constant text value or the contents of another buffer may be
concatenated either in front of or behind data in the buffer. Data can also be
retrieved from a Substitution Table and entered into the buffer. Data can
then be output from the buffer (see Figures 4-14a and b) and placed
anywhere on the form, in any format and may also be retrieved using
another one of FormSprint’s special functions.
Figure 4-14a – To load data to the buffer, enter an Output page “B”, press
ENTER and put a starting buffer line at the bottom of the screen. Select
Front, Back, or Replace when loading the data.
Figure 4-14b – To print data from the buffer, enter “B” for the INPUT page
number, then enter the beginning buffer line and the last buffer line.
All buffer loading is executed before any other Spool Mapper processing.
Therefore, you can not load to a buffer, print the data from the buffer and
then go back to modify the buffer for some other reason. You can, however,
perform a series of steps within the buffer replacing or adding to the contents
of the buffer each time, and then use the end result in your form. Data
placed in buffers is also automatically loaded to memory pages. This
enables the user to capture header or other information appearing on the
first of a series of pages and carry it forward and print it on subsequent
pages.
To ‘print’ data to a buffer, enter the input line or lines and start and end
columns and OUTPUT page ‘B’ (no need to enter output-positioning
parameters when putting data into the buffer), press ENTER. You have a
number of choices relative to the way in which data is loaded to the buffer.
First, select whether you want a Right or Left trim of the data. A left trim will
remove all blank spaces to the left of your data; a right trim will remove all
blank spaces to the right of your data. Select the buffer number at the
bottom of the Fonts and Functions screen.
The buffer number you select is your choice (there are 300 buffer lines
available), however, you may want to reserve buffer one (please refer to the
section in this chapter that deals with buffer one functions) which is used for
a number of unique special features. Each line has 250 character positions.
Often, it makes sense to use the same buffer lines as the data lines being
In the example illustrated by Figure 4-16, data has been loaded to a series
of buffer lines. A special function is used to mark certain types of lines with
the * character. The Print If function is used in a second pass through the
data to REPLACE the marked lines with spaces – thereby eliminating these
lines. Other “passes” could be made through the data to eliminate additional
data fields.
When selecting a range of lines for loading to a series of buffers, the starting
line can be larger than the final line. This causes processing to work
backward through the series of lines. This can be particularly useful when
propagating a control character through a series of buffers and the trigger for
beginning the propagation is at the end of the series instead of the
beginning. Note that when the input line processing is reversed, the output
buffers are also loaded backwards, so that the order of the buffers will be the
same as the order of the input. For example, if you are loading lines 5 to 1 to
a series of buffers, and you select the output buffer as 5, then lines 5 to 1 will
Figure 4-15b – To keep the data organized, it may be helpful to output to the
same buffer lines as the input data lines – in this case, data lines 10-30 are
output to buffer lines 10-30. Note the macro call being loaded In Front –
“&%M1”.
Figure 4-15c – This screen illustrates the loading of the contents of one
buffer (2) to another series of buffer lines (beginning with buffer 4).
Figure 4-16 – After marking certain types of lines, a second pass through the
buffers replaces these lines with spaces – leaving the remaining data clear.
At the same time you are loading to the buffer, you can choose to add the
contents of another buffer (see the example in Figure 4-15c), add text as a
literal (put text in double quotes) or add a macro or graphic call (see this
example in Figure 4-15b – note – the macro is also enclosed in quotes).
Select either “In Front” or “Behind” to define how you want the data added.
For example, if you wanted to add the literal “ICS-“ to the front of a purchase
order number from the spool file, select the input line and columns of the PO
number and output to page B on the first Spool Mapper screen (Figure 4-
17). Next, press ENTER, in the “In Front” field, type “ICS-“ and at the bottom
of the screen, enter a buffer number in the “Load to front of buffer number
___” field. When you want to print the PO number, use INPUT page B and
the buffer number you selected (make sure that the start/end columns you
select are wide enough to include the PO number plus the letters “ICS-“. The
coding for this example is shown in Figure 4-18.
Figure 4-17 – The Spool Mapper is used to select a Purchase Order number
to be loaded to a buffer.
Figure 4-18 – The letters “ICS” are added to front of the PO number.
Figure 4-19 illustrates how the buffers are used for a simple concatenation.
This example works with a print file in which the City, State and Zip fields
appear on separate print lines and are not concatenated. The technique
here is to take the City field at its full width and load to the front of a buffer
(buffer 1 in this case) – the buffer now looks like this – CITY. Second, we
load the state to the end of buffer one and add a comma and a space in front
of the ST– the buffer now looks like this – CITY, ST. Finally, we add the zip
code to the end of buffer one with a space in front of the zip code – the
buffer now looks like this – CITY, ST 12345-123411. Note that any spaces
that may have been to the right of the city when it was loaded to the buffer
are ‘compressed’ out when data is added to the end of the same buffer,
Figure 4-20a – The Spool Mapper coding for the simple concatenation
shown in the previous figure.
Figure 4-20b – On the Fonts and Functions screen, the comma and space
are added to separate the CITY and ST.
Whenever you retrieve data from the buffer, enter the letter B in the INPUT
page column. Enter the Start and End lines that correspond to the start and
end buffer lines, and then enter the start and end columns (which may or
may not be the same as what was originally entered to the buffer). You can
use conditional logic to print to the buffers and you can use conditional logic
to print out of the buffers. You can also print from one set of buffers to
another or back to the same set of buffers. If you are printing from one set of
buffers to another, both your input page number and your output page
number will be B.
The ability to print back to the same buffers or to other buffers allows you to
invoke multiple conditions for handling data. This ability would for example,
permit you to ‘label’ line types within the detail section of a form. The sample
spool file shown in Figure 4-21 shows typical invoice detail data with various
distinct line types; comment lines, pricing lines, and date lines. As with most
forms of this type, we don’t know how many of each type of line there could
be, but we can recognize the different types of lines by the occurrence of
certain characters in particular positions.
If you look at the sample in Figure 4-21 you will see that the pricing type
lines have a “.” in column 60 (the unit price column) and in column 68. The
Note that by loading the \ character to the front of each line, the column
positions are now slipped one column to the right. The next step is to identify
the different line types. Using the Print If logic (please see Chapter 5 for
more on Print If and Don’t Print If), we look for each line that has a ‘.’ in
column 61. If we find the ‘.’ we load the number 1 to the front of the buffers
(the same buffers). Again using the Print If logic, if we find the ‘/’ character in
column 15, we load the number 2 to the front of the same buffers. Buffers 26
to 48 now look like this:
The Print If logic can now be used to select columns from any one of the line
types. For example, if we want to print the comment lines only, we would
enter the function; FN(PI,”\”,1,1,10,40) – that is, if “\” is in column one, print
columns 10 to 40. If we want the product description only, we would enter
Figure 4-22a – Data is loaded to a series of buffer lines beginning with #26.
Data loaded to the buffers is cleared each time FormSprint goes back to
page one processing. However, data loaded to the buffers is also stored in
memory for access on subsequent pages. When processing the following
pages, recall the memory page for printing, and reload it to the same buffer if
it is to be carried forward to subsequent pages. Entering M for the input page
accesses the memory pages. You cannot output directly to the memory
pages.
The spool file example shown in Figure 4-24a is the first page of a multi-
page Purchase Order. The first page contains header information
Figure 4-22b – As the detail lines are loaded to the buffers, the “\” is loaded
in front of all lines.
Figure 4-22c – The Print If function is used to select certain types of lines
from the buffer for printing.
Figure 4-23 – Printing the contents of the buffer enables you to “see” if the
lines have been marked correctly within the buffers.
that does not carry forward to overflow pages of the same PO (the second
page of the spool file is shown in Figure 4-24b).
Figure 4-24b – The second page of a multi-page PO – note that the header
information does not continue onto this page.
This technique can be used to “mark” certain types of lines and then
replicate the mark from the first occurrence to the end of the page or series
of lines. Suppose, for example, that your invoice program puts the text
“INVOICE TOTALS” a line below the last detail line of invoice data. And
then, several lines follow all containing total information of some kind. This
could leave the total lines anywhere on the page depending on how many
detail lines are in the invoice. What you would really like is to separate the
total lines and put them in a box at the bottom of the page. In addition, you
might be re-mapping the detail data and the total lines may override other
columns, thereby interfering with your re-mapping. Figure 4-27 shows a
sample spool file we can use as an example.
Figure 4-25a – Step 7 in the Spool Mapper takes the contents of memory
and writes it to a set of buffers. At step 8 the new header lines are written to
different buffers.
Figure 4-26 – A page type code of “V” indicates a beginning page of our PO.
Therefore, when the code is V, we wish to REPLACE the contents of buffer
10.
Figure 4-27 – A sample spool file with “floating” totals. Propagation is used
to mark all lines from Invoice Total on down.
Begin by loading your detail lines 17-66 to buffers. Next, use the print if
function to look for the INVOICE TOTAL text and mark the front of the buffer
line with a character such as the *. The coding in the Spool Mapper would
look like this:
Description Page First Last Start End Page Top Left Right
Details to buff 1 17 66 1 85 B
The fonts and functions screen would have the following Special Function:
FN(PI,”INVOICE TOTAL”,1,85,85,85) loading “*” In Front of the line where
the text occurred – loaded to the front of buffer 17.
Next, we would propagate the mark – that is, mark all lines following the
INVOICE TOTAL line with the same indicator - *. The reference on the Spool
Mapper would look like this:
Description Page First Last Start End Page Top Left Right
Prop. Mark B 17 66 1 85 B
The fonts and functions screen would have the following Special Function:
FN(PI,”*”,1,1,1,1) loading column 1 only (the *) to the front of buffer 18 –
buffer 18 because we want to force FormSprint to mark each line from the
first occurrence of the text to the end with our special marking character –
the *. The data in the buffer would now look like this:
* INVOICE TOTALS
* TOTAL PIECES 87
* SUB TOTAL
* FREIGHT CHARGES
Once these lines have all been marked, we could use the Print If function
again along with the VRM (see Figure 4-28) to capture the total lines to
separate buffers where we can access them and use them however we
wish. You could also go back to buffers 17 to 66 and use the Print Not
function to not print lines containing the * in position 1 replacing buffers 17-
66. This would in effect remove these marked lines, leaving the rest of the
data clear to re-map.
The buffers can also be used to “capture” special form macros which could
be used to highlight a line, enclosed data in a box, add a heading box, load a
signature or other graphic and many other special enhancements. The
technique would be to scan data for the occurrence of certain character
strings or text or whatever is the triggering mechanism for the macro. The
macros are then loaded to the buffers and when all data has been scanned;
the macros are printed from the buffers. Lets take a simple report where we
would like to replace ----- lines with nice bold solid lines and highlight lines
having totals by boxing them. The data might look like the example in Figure
4-29.
First, we scan for the dotted lines that could occur anywhere in our data. The
coding would be:
Figure 4-28 – The “Print If” function and VRM are used together to “capture”
the floating total lines and separate them to buffers for retrieval.
The Spool Mapper would also have a reference placing the data on the page
(Figure 4-30a reference 1). You could choose to print the dotted lines and
overlay them with the macros, or you could choose not to print the dotted
lines by using the Print Not function. Then, you would print from the buffers
(Figure 4-30a reference 5) where the macros have been placed using the
first four or five columns only ( & % M # # ) depending on how many
macros you have used (it could easily be more than 10 if you had many
conditions or types of headings!). When positioning the macros, you can
offset the distance from top for proper placement, or the macros themselves
can be defined with a negative offset (the horizontal line, for instance, could
Figure 4-29 – Sample report data showing dotted lines. The form definition
will scan for the dotted lines and replace them with solid black lines defined
as macro 1.
Figure 4-30a – The Spool Mapper showing coding to add form macros.
Figure 4-30b – The “Print If” function is used to identify the dotted lines and
then to load a call for Macro 1 to each buffer line where the lines occur.
Buffer one is used for special types of page processing. This buffer can be
used in the same manner as any other buffer, but FormSprint will always
check buffer one before any other processing to see if there is special
coding being used.
The coding &&n/t (where n represents the page and the /t is an optional
request for a particular source tray) may be loaded to buffer one to signify a
particular type of page to process. As an example, let’s take a simple form
that looks at report data and based on the width of the spool file. This form
will determine if the page is up to 80 columns wide, over 80 and up to 132,
or over 132 and up to 198 columns wide. These three widths will determine
three different page types, one will print portrait, two will print in landscape,
and all will print with different fonts and pitch characteristics. Figure 4-31
shows the Spool Mapper screen for this form. The screen shown in Figure 4-
32 shows the Fonts and Functions screen for the loading of the first page
type – page one. Subsequent Spool Mapper steps determine if there is data
beyond the previous width, and if there is, the page call is replaced in buffer
one (see Figure 4-33).
Figure 4-31 – The Spool Mapper screen for a report format form definition
that selects the proper page type based on the width of the spool file.
Figure 4-32 – The Fonts and Functions screen showing &&1 loaded to buffer
1 – selecting page 1.
Figure 4-33 – If data appears beyond column 85, the selection of page 1 is
REPLACED by a selection of page 2.
Other forms where you might use this page call feature are bank statements
where the first page is quite different from the multiple account summary
pages. Other billing statements are also frequently different on the first page
where the name and mailing information appears and follow-on pages may
just list account information.
Page call coding may also be included in line one of the spool file. However,
where programming changes are not an option, and if there is some way to
determine from the data itself what type of page to process (width of the
data, the page number, the presence or absence of a particular field, etc.)
the page call using buffer one is a powerful option.
Buffer one processing can be used to control what page to process, but it
also can be used to determine what form to process. As with page call
coding, this coding can be included in line one of the spool file, but again,
where re-programming is not an option, the form definition coding in buffer
one can dynamically select a formtype.
When a form change is requested from the buffer, the spool file pages will
have already been loaded as required by the first form definition. This means
that if the new form definition uses fewer input pages than the first form
definition, spool file data will be lost. Therefore, when using buffer one to
change formtypes, the number of input spool file pages for the new form
must be the same as the number of input spool file pages for the originating
form. In addition, the Print Mode and output formtypes will also have been
loaded from the first form definition. Therefore, any other form called will
process with the Print Mode and output formtype of the starting form.
The screen shown in Figure 4-34 is a sample record from a spool file that
contains a number of entries, each containing a field with the sales
representatives’ initials. A form has been developed to get the initials from
the spool file and concatenate them with the &&F: coding to “jump” to the
sales representative’s own introduction letter. A form has been developed for
each sales rep with their unique text and signatures. Within the form
definitions for each of the separate letters, coding is included to see if buffer
one contains a new formtype. In this way, the spool file will move from form
to form as the sales reps initials change within the same spool file. Figures
4-35a and 4-35b show the Spool Mapper coding and fonts and functions
screen for the first form that starts the form jump in our example. Figures 4-
36a and 4-36b show the coding within one of the sales representative’s
letters.
Figure 4-34 – Sample spool file with salesman’s initials on the last line. The
initials will be used to select his unique cover letter.
Figure 4-35a – The Spool Mapper selects the initials from line 10.
Figure 4-35b – The initials are then concatenated with the special coding
&&F:LITLTR to select the proper formtype.
Figure 4-36a – Each unique letter contains the same logic to “jump” to the
next form when the initials in the spool file change.
Figure 4-36b – The Fonts and Functions screen for the salesman’s letter.
Coding can be loaded to buffer one to automatically break the output spool
file. The format for this coding is &&NEW. When FormSprint encounters
this coding, it automatically ends the output spool file and begins a new
spool file.
The Data Mapper screen is used for mapping data to forms using direct data
entry or intermediary file (flat file) data entry. In addition, the Data Mapper
was originally designed to handle spool file processing as well. Forms using
spool file input designed prior to March of 1998 are still supported by using
the Data Mapper. However, new forms using spool file input should be
designed using the Spool Mapper (please refer to the beginning of this
chapter).
On the Data Mapper screen (Figure 4-38) you will be entering positioning,
formatting, and calculation information for the variable data. When variable
data is to come from direct data entry or an intermediary file, each variable
data field can be handled separately using mathematical functions, special
formatting, output styling such as bar codes, or special font selections, all
according to the coding entered in the Equation column. Please refer to
Chapter 5 for instructions on using data formatting and special functions.
Figure 4-37a – The spool file page number is used to determine if this record
should begin a new output spool file.
On the basis of the entries on the Data Mapper screen, FormSprint will
build a data entry screen for direct data input to a form. The Intermediary
File is simply a flat file consisting of fixed length records of 162 characters
each. Each record in the file is keyed to a reference number from the
Variable Text Locations screen. Therefore, the same form definition can be
used for direct data entry as well as intermediary file processing. This allows
for much flexibility in data formatting as well as the use of all of the
FormSprint calculation functions.
The next four columns provide exact positioning information, beginning with
the form page number. In the next two columns (Top and Left), enter the
position for the first letter of the data field on the form. The position is
measured in millimeters from the top and the left edge of the sheet. The data
will print immediately to the right and above the position entered. In the next
column (Right), enter the position of the right edge of the data field. The Left
In the next column (Lines), enter the number of lines required for the data
field. If multi-line data is coming from direct data entry or intermediary file
data entry, FormSprint will provide semi-automatic word wrapping and
editing features within each multi-line data field. Where column alignment is
required, however, format the multi-line field using word wrap suppression
(for example, entering - A4099102/RN in the Equation column, prints the
data in Courier 10 point type, and right justifies with no word wrap.
The example shown in Figure 4-39 is a Data Mapper for a simple invoice
designed for direct data entry or the use of an intermediary file where each
data field is a separate reference number.
Figure 4-39 – The Data Mapper to create a Direct Data Entry invoice.
Reference 1 on the first Data Mapper screen places the Invoice Number on
page 1, 30 millimeters from the top and starting 165 millimeters from the left.
The end of the invoice number field is 182 millimeters from the left. Only 1
line is provided, and the Equation entry changes the font for this field to
Times 14 points. Reference 2 - Date is set up similarly.
References 3-5 define three lines for the Company Name, Address, and
City, State and Zip Code. Reference 6 copies the data placed by Reference
5 (the City, State, Zip) and uses this data to create the postal bar code.
References 7 through 10 comprise the first line of order data. Entries in the
Equation column give the program formatting and calculation information
(please refer to Chapter 5 for Data Mapper functions). References 11
through 14 are identical except for the distance from the top. Reference 15
provides for the total of the order.
Note that you can move to any part of the definition by entering the desired
reference line number at the bottom of the screen following 3-Go To and
then pressing Function Key 3. You can also scroll one screen at a time using
Function Keys 4 and 5.
Insert - By positioning the cursor between two lines and pressing Function
Key 17, you can insert a new line. All equation references will be adjusted
appropriately.
Delete - To delete a reference line, position the cursor under the line to be
deleted and press Function Key 18. The line will be deleted and all equation
references will be adjusted. If any equations referred to the deleted line, the
reference will be changed to ‘?’. An attempt to calculate a form with such
references will result in an error message - Invalid Reference.
Copy - Function Key 10 provides one of the most powerful features of the
form editor, the block copy function. Enter the starting and ending reference
numbers to be copied, then enter the reference number where the copy is to
be placed. The output location need not be blank. If entries are already
present, the system will move them down to make room for the copy. If you
also enter values for stepping the distance from the top and left positioning
parameters, these will be adjusted automatically in the copied lines.
Equation references will be adjusted appropriately.
Look at the bottom of the screen shown in Figure 4-40. The Block Copy
function is used to copy the first and second line of order data R7 to R14 to
R15 and steps the top by 10 millimeters. The second screen of the resulting
Data Mapper is shown in Figures 4-41. Note that Reference numbers in the
Equation column are automatically “bumped”. The Grand Total, which was
originally at R15, is pushed down to R23 and will now include the new lines
of order data as well.
Functions 5-1
Integrated Custom Software, Inc.
FN(MA,Op,Val,Format) – MATH FUNCTION
FN(PI,aaa) - PRINT IF
FN(PI,*Lccc) - PRINT IF (with list of acceptable characters)
FN(PI,”aaaaa”,S1,S2,P1,P2) – PRINT IF (selection and print characters
separate)
FN(PI,”>aaaaa”,S1,S2,P1,P2) – PRINT IF (comparison values use greater
than/less than)
FN(PN,aaa) - DON'T PRINT IF
FN(PN,*Lccc) - DON'T PRINT IF (with list of characters to suppress)
FN(PN,”aaaaa”,S1,S2,P1,P2) – DON’T PRINT IF (selection and print
characters separate)
FN(PN,”>aaaaa”,S1,S2,P1,P2) – DON’T PRINT IF (selection and print
characters separate)
FN(PI,”*Bn”,S1,S2,P1,P2) - PRINT IF (comparison value=buffer number)
FN(PI,”*Mn”,S1,S2,P1,P2) – PRINT IF (comparison value=memory page)
FN(CN, TABLE,N,L,”a”)
Functions 5-2
FormSprint Instructions
Figure 5-1 – The Fonts and Functions screen is used to enter functions.
Figure 5-2 – The Data Mapper Equation field is used for entering Special
Functions.
Functions 5-3
Integrated Custom Software, Inc.
Functions 5-4
FormSprint Instructions
using the CHECKNUM program, and then each time the value is accessed
during form processing, the value is automatically incremented. The base
value can be reset at any time using the CHECKNUM program.
The parameters N, L, and “a” are optional. If not provided, a value of 1 will
be used for N and the length will equal the length of the returned value. N
must be provided if L is used. If L is provided but no value is provided for “a”,
then the output will be padded with spaces to return the requested length.
For example, if the check number needs to be ten digits long, padded with
zeros on the left, with an increment of 1 each time the function was called,
and the number table is called CHECK, the function would be:
FN(CN,CHECK,1,10,"0")
With spool file processing, if the number is to be output only once on the
form, simply enter the output location on the form, any font specifications
desired, and the function in the Special Functions field. If the number is to be
used in multiple locations output the number to the buffer the first time and
set the increment to 1. Each subsequent use of the number can be done by
using the buffer as input (along with any special font designation) - no
additional function calls.
If direct data or intermediary file processing is being used, the function can
be entered on any variable reference number. It can be combined with font
specification. The output will appear in accordance with the page and
vertical and horizontal coordinates defined for the particular reference
number. The number of lines should be set to 1. However, with direct data or
intermediary file processing, FormSprint does not store the number in the
copy buffers. Therefore, if the number will be accessed more than once in
the form, the check number function must be used each time the number is
required. In this case, the increment value should be set 0 so the number
doesn’t change until the last use, when the increment would be set to 1 in
preparation for the next form.
FN(CS,V,GSIGN)
FN(CS,>V,GSIGN)
Functions 5-5
Integrated Custom Software, Inc.
FormSprint’s Check Signature Control Function offers control over the
printing or suppressing of signature graphics on checks based on the
amount of the check.
The amount field to be tested can come from a direct data entry location,
from an intermediary file, or from a spool file. The location of the signature or
macro is determined by the output Distance from Top and Left on either the
Spool Mapper screen or Data Mapper screen. The function is entered into
the Special Functions field of the Spool Mapper or the Equation column of
the Data Mapper.
In the example shown in Figure 5-4 the user wishes to put one signature on
every check below $10,000. For checks of $10,000 or above, two signature
lines are to appear with text reading “Two signatures required on checks
above $10,000” (in this case, both signatures will be done by hand if the
check exceeds $10,000).
Functions 5-6
FormSprint Instructions
To begin, a macro is created consisting of two horizontal lines and the
centered text “Two signatures required above $10,000”. This becomes
Macro 2 in this form.
A reference is entered in the Spool Mapper to point to the Input line and start
end columns of the amount field of the spool file. Output locations are
entered for the position of the signature graphic file if the amount is below
$10,000. Then, the Check Signature Function is entered into the Special
Functions field of the reference - FN(CS,10000,SIGN). A second reference
is entered using the same input line and start/end columns. The output
location is based on the position of the macro which will be placed if the
amount exceeds $10,000, again the Check Signature Function is entered
into the Special Function field - FN(CS,>10000,M2). The GSIGN parameter
can contain either a graphic file name (as in our first sample reference), a
macro (as in our second example), or the number assigned by ICS if you are
using a signature cartridge or SIMM/ DIMM provided by ICS.
Figure 5-4b – In this format, the Check Signature Function will place a macro
if the dollar amount exceeds $10,000.
The current date can be merged with the input variable data using the date
function in the Special Functions field of the Spool Mapper or in the Equation
field of the Data Mapper.
Functions 5-7
Integrated Custom Software, Inc.
The function is of the form: FN(DT,n) - where DT accesses the date function
and n is the date format identifier. The formats are:
1 - November 1, 2001
2 - NOVEMBER 1, 2001
3 - Thu November 11, 2001
4 – THU NOVEMBER 1, 2001
Input parameters must be specified (use a ‘default’ entry of start line 1 to end
line 1 and columns 1 to 10) when using the date function with the Spool
Mapper, however, the program ignores these entries. Next, enter the output
location and include any font specifications desired, and enter the function
call in the Special Functions field. If the date is called multiple times, you
could output the date to the buffer the first time and then simply use the
buffer as input for each subsequent placement of the date.
When using the Data Mapper, you will need to use the function each time
you need to output the date to the form.
FN(DA,n)
The date converter function takes a numeric date from your spool file and
converts it into words. Enter the function in the Special Functions field of the
Spool Mapper. The input data must be in the format MM/DD/YY or
MM/DD/YYYY. The format of the output is selected with the “n” parameter
and is identical to that for the current date function described above. If the
input data is not formatted correctly, the input data will be printed without
modification. This function is not available for use with the Data Mapper.
The function is called from the Special Functions field of the Spool Mapper in
the format:
The function works from the beginning of the line or field as described by the
input start and end columns on the Spool Mapper. The function replaces
each character with the selected replacement character until the input data
character is not a zero and not a space.
Functions 5-8
FormSprint Instructions
For example, to eliminate leading zeros, the function would be: FN(ED, ) or
FN(ED).
The Spool File Extract Function retrieves various parameters from the input
spool file. These parameters can be printed on the form, or used in
conjunction with conditional printing or the Substitution or Distribution Tables
for alternate processing. The output location is specified with the output
parameters in the Spool Mapper or Data Mapper (this could be a print
location or it could be a buffer). The input parameters must be present, but
are not used by the function.
FN(EX,aaa) where EX identifies the extract function and aaa defines the
parameter to be extracted. The values of aaa are:
SPF – Input spool file name
SPN – Input spool file number
JOB – Job that created the spool file
JBN – Number of the job that created the spool file
USR – User profile for the spool file
USD – The User data field for the spool file
PGS – Total number of pages in the spool file
One might use the extract function, for example, to determine the type of
page layout. You might have an application program that creates spool files
using the same printer file and therefore, having the same formtype for
invoices, quotations and agreements. The processing of these different
types of forms might be the same, but you would like the appearance of the
forms to be different. Perhaps the Job name would tell us which type of data
we have. Begin by defining different macros (see Chapter 3) for the different
page layouts – Macro one for the invoices, Macro two for the quotes, and
Macro three for the agreements. Then, use the extract function to extract the
job name and output to a buffer. For purposes of our example, suppose the
Functions 5-9
Integrated Custom Software, Inc.
job name prefix is INV if the data is an invoice, QTE if it is a quotation and
AGT if it is an agreement. Figures 5-5 and 5-6 show the Spool Mapper
coding of one method to accomplish the change of form layout based on job
name.
Figure 5-5a – In this example, a form macro will be chosen based on the
spool file Job.
Figure 5-5b – The Extract function pulls the Job name and loads to B1.
Functions 5-10
FormSprint Instructions
Figure 5-6 – In this step, if the prefix of the Job name is QTE, a call for
macro 2 is placed in buffer 15 – macro 2 is the form layout for the quotation.
Functions 5-11
Integrated Custom Software, Inc.
Figure 5-7a – The spool file page number is selected and the literal “Page” is
added in front, and the whole thing is loaded to buffer 8.
Figure 5-7b – The Extract is then used to extract the total pages from the
spool file. The literal “of” is added in front and the result added to buffer 8.
Functions 5-12
FormSprint Instructions
Alternate Font Support
Font changes can be made on the basis of the content of the input spool file
data stream to an alternate font specified in the Special Functions field of the
Spool Mapper. This function is only supported for spool files with
unformatted text (not set flush right or centered).
For example, you could begin using a bold font in the middle of a line by
specifying an * for the start up character and then putting the * in the spool
file where you wanted bolding to begin. In this case, you would specify that
the * be either removed or changed to a space, depending on how the spool
file was written.
Another example would be to bold the word 'Total'. In this case, the control
characters would be the word 'Total', the stop control character would be a
space, and the control characters would be retained for printing.
Or, perhaps the words FINANCE CHARGE must be in a different font from
the rest of the text. By specifying FINANCE CHARGE as the control
characters, specifying a space as the stop control character, and retaining
the control characters for printing, every time the words FINANCE CHARGE
appeared, it would be printed in the alternate font.
The start and end control characters are entered, separated by commas and
are not case sensitive.
The basic font and the alternate font must both be either proportionally
spaced or fixed pitch fonts. Color and shading are not supported.
Functions 5-13
Integrated Custom Software, Inc.
FN(IN,"aaaa","bbbb")
The field insertion function permits the addition of text before and after data
from the input spool file or from an intermediary file. For example, a prefix
and suffix could be added to a fax number to support fax device coding or
punctuation could be added for mass mailings.
The function is entered in the Special Function field of the Spool Mapper, or
in the Equation field of the Data Mapper.
FN(PI,aaaaaa) - where PI accesses the Print If function and the line or field
will be printed if the character string aaaaaa is found, and:
FN(PN,aaaaaa) - where PN accesses the Don't Print If function and the line
or field is suppressed from printing if the character string aaaaaa is found.
The series aaaaaa can contain any characters, need not be complete words,
and can contain spaces.
The character search can also be on the basis of a list of acceptable (print-if)
or unacceptable (don't print-if) characters. The list is introduced by the code
Functions 5-14
FormSprint Instructions
*L. Thus, for the print-if function using a list, the format would
be:FN(PI,*Lccccc) - where ccccc represents the acceptable character list.
The output will be printed only if every character in the input data appears in
the list. For example, if you wanted to print data only if it contained numbers,
the function would be: FN(PI,*L1234567890).
If anything in the input data were not a number, the data would not be
printed. If the input were a dollar amount, you would need to expand the list
to include commas, decimal points, the dollar sign, spaces, and maybe even
the credit CR following the number. In this case, the function would be:
FN(PI,*L1234567890+-, .CR)
The don't print-if function is the inverse. If any of the characters in the list
appear in the input data, the line will not be printed. For example, if your
spool file has remarks and notes that were to be suppressed and these were
indicated sometimes by & and sometimes by /, the function would be
FN(PN,*L&/)
In this case, any line containing an & or / anywhere in the line would not be
printed.
Enter the function call in the Special Functions field of the Spool Mapper.
The sequence of characters can appear anywhere in the line, but if using the
Spool Mapper, the only area scanned when using this type of conditional
printing will be that part of the line defined by the input start and end
columns.
The example shown in Figures 5-8a-c shows a sample spool file with the
Total line showing below the details. In this example, the goal is to print the
details in plain type and the total line in BOLD. The Spool Mapper includes a
reference line using the Print Not function if TOTAL is in the line in a specific
position. Figure 5-8c shows the Fonts and Functions screen with the Print
Not function.
Functions 5-15
Integrated Custom Software, Inc.
Figure 5-8b – Step 2 in this form definition will print the details while stepping
over the TOTAL line wherever it falls.
Functions 5-16
FormSprint Instructions
Figure 5-8c – The Print Not function is used to locate the line with the
TOTAL and print all detail lines except the TOTAL line.
When using the Print If and Don’t Print If in this format, the columns entered
for the Start and End columns on the Spool Mapper screen should
encompass the entire line (the function itself gives the starting and ending
columns for the selection data – see the example above in Figures 5-8a-c).
The list function can be used in this type of conditional printing by including
the *L within the quotes around the selection character string. For example,
an entry of: FN(PI,”*L0123456789”,1,5,10,20) selects the Print If function
and instructs FormSprint to print columns 10 to 20 if columns 1 to 5 are
numeric. In addition, relative comparisons are also permitted by using the <
or > sign in front of the character string or the buffer/memory location. For
example: FN(PI,”>B17”,1,30,1,30).
Note that leading and trailing spaces are included in the comparison if they
are contained in the buffer data. These spaces can be eliminated if desired
when the buffer is initially loaded. If the input buffer contains no data the
print if function will fail and the don’t print if function will pass.
Functions 5-17
Integrated Custom Software, Inc.
When conditional printing is done without the selection by start and end
columns, the selection data is not case sensitive. When selection is made by
using start and end columns, the character string for comparison is case
sensitive. Also, the selection criteria can be a space or spaces in this
expanded type of conditional printing, but spaces can not be used for
selection when using the function without start and end columns.
Please see the example of this function in Chapter 4 under Spool Mapper
Buffers. The example illustrates how this function could be used to
completely reformat spool file data by identifying line types.
If using direct data entry or intermediary file processing, the only acceptable
format is FN(PI,aaaaa) or FN(PN,aaaaa).This function should be entered in
the Equation field of the Data Mapper.
FN(FX,aaa)
Functions 5-18
FormSprint Instructions
then, enter the Fax Support Function in the Special Functions field in the
Spool Mapper, or in the Equation column of the Data Mapper. When using
the EMAIL parameter, the function loads the email address and also
automatically sets the parameter *DS for e mailing.
With the Cma Ettworth IMPS support, formatting the fax telephone number
as #NNNNN will interpret the number as an IMPS short code and load the
dial string with Dial Code 0 for short code support.
Note that these support functions can be imbedded in the substitution table
function to incorporate look-up tables for extracting any of the values
required for fax support. This use of the fax support function is described in
the section on the Substitution Table.
When using FormSprint's FaxStar function, simply select the input line and
columns from the spool file (or use the TRIM and COPY commands with the
Data Mapper) to isolate the fax number, then add the coding FN(FS,UUU)
in the Fonts and Functions field (or in the Equation column). FormSprint will
extract the fax number and format it properly. UUU can be a specific user
profile, or *USR can be used to load the user profile of the creator of the
input spool file. Alternatively, *NONE can be used to provide fax number
formatting with no notification.
Functions 5-19
Integrated Custom Software, Inc.
The Spool Mapper Math function permits mathematical operations with spool
file data. Addition, subtraction, multiplication, and division are supported.
The function takes a numeric value identified by the input parameters on the
Spool Mapper screen, performs the math function using the second operand
defined in the math function, and then formats the data using the format
specification of the math function. The output is printed or loaded to a buffer
as defined by the Spool Mapper output parameters. All input values are
stripped of extraneous nonnumeric leading and trailing characters. A trailing
CR is interpreted as a negative sign.
Math operations are defined using the special function field on the second
screen of the Spool Mapper. The function is of the form:
FN(MA,Op,Val,Format)
Where: MA defines the math function
Op is the math function to be performed and must be +, -, /, or *
Val is the second operand. The second operand can be a number
or can point to a buffer or memory location. To point to a buffer or memory
location enter B and the buffer number or M and the memory number. If a
series of input lines are being processed, the second operand buffer or
memory number will be incremented with each new input line.
Format is the desired output format. It consists of an optional
currency character, a #, a comma if commas are desired in the output, a
decimal point if a decimal is desired, followed by the number of decimal
places marked with # signs. For example, $#,.## would output with a $ and 2
decimal places with commas.
Some examples:
To add two columns, you would first load one column into a series of buffers,
perhaps starting with buffer 10. The Spool Mapper would then input the
second column and the math function would be: FN(MA,+,B10,#.##) with the
output going directly to print or to another set of buffers for further
processing.
To calculate cumulative totals from a column, the column is read and added
to a series of buffers with an offset of 1. For example, if the input column of
numbers was in lines 10 to 20, the input values would be added using
buffers 9 to 19, while outputting to buffer 10 to 20. The math function would
be FN(MA,+,B9,#.##). When line 10 is processed, the value in line 10 is
added to the value in buffer 9 (which has nothing in it and is 0) the output is
placed in buffer 10. When line 11 is processed, its value is added to the
value in buffer 10 so we now have the sum of lines 10 and 11 and the output
is placed in buffer 11. At completion, the sum of values in lines 10 to 20 is in
buffer 20.
Functions 5-20
FormSprint Instructions
The example shown in Figure 5-9 shows the Fonts and Functions screen for
a direct deposit form. In this example, a gross amount is being calculated by
multiplying the hours by the rate.
Figure 5-9 – The Math function takes the first operand from the Spool
Mapper Input. The second operand in this example is loaded in buffer 133.
The result will be formatted with two decimal places and placed in buffer
170.
To number the pages in sets based on the contents of the input spool file,
identify the location in the spool file that is to be compared from page to
page, using the input parameters of the Spool Mapper or the trim functions
of the Data Mapper. Then enter the function: FN(PG,C) in the Special
Functions Field or the Equation field of the Data Mapper.
Functions 5-21
Integrated Custom Software, Inc.
The search and replace function searches for a string of characters and, if
found, replaces the string of characters with another string. Multiple
occurrences can occur in a single line and all will be replaced. The character
strings do not have to be the same length. The format of this function is:
FN(SR,”string1”,”string2”) – where: SR designates the search and replace
function
String 1 is the character string to be replaced
String 2 is the replacement character string.
The replacement character string can have zero length in which case, the
first character string would simply be deleted. The coding for this use of the
search and replace would be: FN(SR,”string1”,””). Spaces are also valid
characters in this function either as the character to be replaced or as the
replacement character.
The form page definition to be used for processing and the input paper tray
and page size can be selected dynamically on the basis of the contents of
the input spool file. Note, however, that these functions are available only
when the variable definition is defined using the Spool Mapper.
The following example illustrates one way in which you might use the tray
select function. Suppose you have an application that requires that the first
page of your document be printed on special letterhead, which you have
loaded in Tray 4 of your printer. Pages 2 and 3 of your document are copies
and do not need to be printed on letterhead. Enter a reference on your Spool
Mapper similar to the one shown in Figure 5-10a for Output page one with
the function FN(TR,4) on the Fonts and Functions screen (Figure 5-10b).
Note that the input and output parameters are not used by FormSprint
except for the Output page number which must be correct. If input tray 1 is
your default (on the Print Default Values screen) and if both pages are to
come from tray one, there is no need to use the tray function for these output
Functions 5-22
FormSprint Instructions
pages. However, if other trays are required or if the form may flip back and
forth between trays, enter a tray selection function for each page.
Figure 5-10b – The tray number can be coded into the function, it can be in
the spool file, or it can be derived from another function.
Functions 5-23
Integrated Custom Software, Inc.
In a more complicated example, you may need to have only the first page of
a multi-page form print from one tray (perhaps the tray is loaded with
expensive letterhead) and any subsequent pages should print on plain
paper. This situation would require some field in your spool file to test to see
if the page/record you are processing is a single page invoice or if it is a
continued page. Perhaps you could look at the page number which might be
in the format “Page 1 of 1” or perhaps if the page number is anything except
1 you know that you want to pull from a different tray. You can use the Print
If function and the Tray select function to dynamically select the tray. The
example shown in Figures 5-11-a-d illustrates this example. Figure 5-11-a
shows the spool file and the positioning of the page number. Figure 5-11b
shows the Spool Mapper for this form. Figure 5-11c shows the coding to use
the page number field and the Print If function FN(PI,” 1”,50,53,53,53) to
load tray one and letter size paper for page one to buffer 1. A Print Not
function is also entered to test if the page number is not 1(Figure 5-11d)
When the page number is NOT 1, 4 will become the tray select and legal
size (paper size 3) will become the paper size selection. Finally, the buffer is
used as input to the Tray select command.
Figure 5-11a – A sample spool file showing the position of the page number.
Page Select
To specify a form page based on the contents of the data and, optionally,
tray selection, load the control codes &&pp/tt to Buffer 1, where pp is the
Functions 5-24
FormSprint Instructions
Figure 5-11b – The form definition includes a step to identify first page and a
continuation page.
Figure 5-11c – If the record is a first page, tray 1 and paper size 2 are
loaded to the buffer (size 2= 81/2X11).
Functions 5-25
Integrated Custom Software, Inc.
Figure 5-11d – If the page number is anything but 1, tray 4 and paper size 3
are loaded to the buffer (size 3=legal). The buffer contents will then be the
input to the tray select function.
form page to be used and tt is the printer tray number (see Chapter 4 for
more on this feature). If only a form page is to be specified, the tray number
can be omitted. It is important to note that when using the &&pp/tt function,
the variable form definition must specify the input page as page one for all
pages. The input page will be processed only for the specified output page.
Specifying an input page other than one for any of the pages will result in
lost data.
This function might be used for an application where you have different page
types in your form and depending on the data coming from the spool file, you
wish to process one way or another. For example, you may have an invoice
form that puts totals only on the last page and you would like your form to
not include the total boxes until the last page is reached. Therefore, you
have a page one type - no total boxes and a page two type that includes
total boxes. By looking at the spool file on a particular line, you can
determine if this is the last page or not – for example, line 67 includes the
text “Order line total”. Use coding similar to that shown in Figures 5-12 and
5-13 to load first the page one-type selection and then the page two-type
selection if we are on a qualifying last page. Note that this function does not
permit making copies of the form pages, as only the page loaded in Buffer 1
will be processed.
Functions 5-26
FormSprint Instructions
Figure 5-12 – A specific page can be called based on the input data.
Figure 5-13 – In this example, page two processing is only called when the
Order line total is present.
Functions 5-27
Integrated Custom Software, Inc.
Dynamic Output Tray Function
Generally, the output tray is selected on the Printout Default Values screen
(see Chapter 1). However, just as you can dynamically select an input tray
and paper size, you can also dynamically select the output tray. To select
the paper output tray, use the function: FN(OT,n) where OT defines the
output tray function, and n is the output tray number. The tray number may
also be selected on the basis of the input data itself (either data within the
spool file or data loaded to a buffer). To select output tray on the basis of the
spool file or buffer data, use the function: FN(OT).
The example shown in Figures 5-14a and 5-14b show the Spool Mapper and
Fonts and Functions screen for a form where we scan for the text “HOLD” in
an address field. If we find the text, we load the number 4 replacing the
contents of buffer 10 (preloaded with a 1). This buffer then becomes the
input selection on the Spool Mapper for the Output Tray function. If we found
the text, the tray will be a 4, otherwise, the selection will be tray 1.
Figure 5-14a – In this example, the Output tray will be selected on the basis
of the input data.
Variable Substitution
Functions 5-28
FormSprint Instructions
Figure 5-14b – If the text “HOLD” is found in the spool file, an output tray
number of 4 is loaded to a buffer.
Figures 5-15a,b and c show the Substitution Table Editor. To create the
Table initially, enter Option 1 - Create Table in an available location and
press ENTER. When the table has been created, select Option 6 - Add
Records to your new table. Option 2 allows you to make changes to an
existing table and Option 5 allows you to display an existing table. The
COPY Option (Option 3) permits you to copy an entire table or to print the
table for your documentation. The screen shown in Figure 5-16 shows the
COPY Option screen with data entered for printing the table. Note that the
output queue we are using is an ICS virtual queue. The print file uses the
formtype SUBTABLE - a matching form definition is supplied by ICS or can
be produced by the user to meet specific requirements.
Functions 5-29
Integrated Custom Software, Inc.
Figure 5-15b – Each Substitution Table has its own security list. The default
security level is PUBLIC.
Functions 5-30
FormSprint Instructions
Figure 5-15c – Entries in the Sub Table contain a Key Value and a maximum
of 12 parameters that may be associated with the Key Value. A default value
of ELSE may also be included.
When building the table, enter the Key Value at the top of the screen and the
parameter or parameters to be substituted in the bottom portion of the
screen. Parameters may be text, a macro call (in the format &%M1 - making
the M uppercase), or a graphic file (in the format &%GRAPHIC). To add the
next entry, press the ENTER key.
A key value of ELSE (uppercase) may be entered into the substitution table.
If the ELSE record is present, the parameter or parameters associated with
the ELSE will be substituted whenever none of the other key values are
found. Many times, the ELSE value will have no parameters associated with
it because if the key value is not found, you may not wish to make any
substitutions. Also, if the key values are not found and there is no ELSE
value, but there is input data in the field tested, the input data will print in the
output location specified for the substitute value.
Once the table is created, the security control for your table can be accessed
by using Option 14 for the specific table to be controlled. The first entry in
this table is the public access security level. Users not specifically listed
have the access level defined for the public. If an individual user profile is
listed, the security level for the individual will prevail, and may be higher or
lower than the public access level. The default setting is full security access
for the public.
Functions 5-31
Integrated Custom Software, Inc.
Figure 5-16 – The COPY option is used to either copy the table to another,
or to print the table listing for documentation.
Three levels of access are available: S-full access and security control, E-
edit and display rights but no access to the security table, and N-no access.
Users defined as FormSprint administrators (as defined in the
Administration functions of the FormSprint Editor) with security level for
FormSprint also have security level access for all tables, regardless of
entries made in the substitution security table. Note that the security level
defined in the Substitution Table administration program only limits access
within this program, it does not limit access to use the table from a form
definition.
When using spool file input, enter the Input line and start and end column
numbers of the field to be tested. Then, enter the Output Distance from Top,
Left and Right where the substituted text, macro or graphic file will be
printed. A font specification may be added also. Enter the function call in the
Special Function field of the Spool Mapper or in the Equation column in the
Data Mapper. Macros or graphics will be positioned by their upper left-hand
corner.
Functions 5-32
FormSprint Instructions
The ability to introduce macros as substitution values permits the entire flash
portion of the form to be selected on the basis of the content of the input
data. Or, the flash portion of the form can be substantially changed on the
basis of the input data.
Any of the other FormSprint functions can be linked after substitution table
processing. In this case, the parameter value, P, must be included. The two-
Functions 5-33
Integrated Custom Software, Inc.
Figure 5-17b – This screen shows what the spool file might look like when
the check overflows.
Figure 5-17c – Line 19 becomes the input to Step 11 in the Spool Mapper
and the input to the Sub Table function.
Functions 5-34
FormSprint Instructions
Figure 5-17d – The Special function is entered on the Fonts and Functions
screen.
The VR function permits the placement of variable data relative to the last
variable data printed rather than at an absolute millimeter position. In the
distance From Top for Output on either the Spool Mapper or Data Mapper
screens, enter the relative distance (the millimeter offset below the last
printed line) rather than an absolute position. Then, in the Special Functions
field on the Fonts and Functions screen of the Spool Mapper or on the
Equation line of the Data Mapper, enter VR to select this function. The VR
function may be used in conjunction with another function entry on the Fonts
and Functions screen.
Functions 5-35
Integrated Custom Software, Inc.
The example in Figures 5-18a and 5-18b show an invoice form where we
wish to print a message several lines below the last detail line. The message
appears in a fixed location in the spool file at the very bottom of the page.
The Spool Mapper shows a reference with the message as INPUT and an
OUTPUT distance from top of 8mm (about 2 print lines). The Fonts and
Functions screen for this reference shows the VR coding making the 8mm
distance relative to the last thing that was printed (in this case, the last detail
line).
Multi-line processing is invoked by using the VRM function. With the VRM
function, all blank lines are removed and each non-blank line is positioned
relative to the previous non-blank line by the millimeter distance entered in
the “Distance From Top” parameter of the Spool Mapper. The entry for lines
per inch is ignored.
Output to a buffer using the VR function causes the first non-blank line to be
written to the designated buffer. Subsequent lines called from the same
variable definition reference are written to the sequential buffers, with blank
lines left for blank input lines or lines not qualifying through conditional
printing. The VRM function for buffer output compresses out all blank and
non-qualifying lines. Figure 5-19 graphically shows what the same data
would look like if written to the buffers using first the VR function and
secondly using the VRM function.
Functions 5-36
FormSprint Instructions
JOHN SMITH
ABC MANUFACTURING
112 MAIN STREET
ANYWHERE, CT 06033
JOHN SMITH
ABC MANUFACTURING
112 MAIN STREET
ANYWHERE, CT 06033
Figure 5-19 – This figures shows how data might appear using first VR and
secondly the VRM function.
The VRM function might be used to select a line from the spool file (like a
floating Total line) by using conditional printing and then output directly to the
Functions 5-37
Integrated Custom Software, Inc.
page, or to a buffer. The screen shown in Figures 5-20 shows a sample
spool file with floating total lines. The coding shown in Figure 5-21-a and
Figure 5-21b shows how these lines are identified and loaded to buffers
using the VRM function. If using buffers, you can simply output the qualifying
data from the buffer whenever and wherever it is required on the form.
Figure 5-20 A sample spool file showing “floating totals” – in other words, we
don’t know where they will appear.
The following functions are used only in conjunction with the Data Mapper
variable text editor, and only for direct data entry forms, intermediary file
forms, or with forms designed for spool file processing prior to March of
1998. All Data Mapper functions are entered in the Equation field of the
Data Mapper screen. Multiple equations can be used for a single reference
by separating each entry with a space. In order to accommodate all desired
options, equations can be entered on multiple reference number lines, but
avoid splitting equations over reference lines. The following is a list of Data
Mapper functions:
Functions 5-38
FormSprint Instructions
Figure 5-21a – The Total Lines (there are three of them) are “marked” within
the buffers and then separated using the VRM function.
Figure 5-21b – The lines having the word TOTAL in specific columns will be
separated using the VRM function so they may be placed precisely.
Functions 5-39
Integrated Custom Software, Inc.
NP - SUPPRESS PRINTING
The fonts used for variable data can be changed in terms of typeface,
boldness, lines per inch, pitch, format, or rotation. The font function is of the
format:
Afffff/w/l/p/c90
The letter ‘A’ tells the program that the function is a font selection.
fffff - Represents the specific font number (typeface, point size, and symbol
set). Refer to the back of this Instruction Manual for supported font numbers.
w - Represents the print weight (1 for plain, 4 for BOLD), color can be added
to the weight parameter for white or gray (i.e. 14 white bold, or 404 a 40%
gray shade bold type) or a specific number from a color palette could be
used for color laser printing.
l - Represents lines per inch. Any lines per inch can be selected; the only
real constraint is readability. This parameter can also be entered in fractions
for fitting variable data precisely in a specified area of your form (i.e. 6.5
lines per inch could be selected rather than the standard 6 lpi).
Functions 5-40
FormSprint Instructions
All numeric font parameters are positional in the font selection function.
Therefore, if pitch is the parameter to be changed, weight and lines per inch
must also be specified and each parameter is separated by a forward slash
/. For example, an entry of A4099122/1/6/10.6 selects Courier (4099...), 12
points (409912.), Roman 8 symbol set (4099122), plain text (4099122/1), 6
lines per inch (4099122/1/6), and changes the standard 10 characters per
inch to 10.6 characters per inch (4099122/1/6/10.6). Format characters are
alpha characters and therefore, are not positional. An entry of A4099122/LN
selects Courier, 12 points, and simply suppresses automatic word wrapping.
Barcodes
Barcodes are selected by entering specific codes in the Equation field of the
Data Mapper screen:
where hh is the height of the bar in mm and ww is the width of the thinnest
bar in dots (300 dots/in.). For example, a code of B12/5 produces Code 39
code 12 mm high, with the thinnest bar 5/300 in. wide. Do not use hh/ww
with Postal barcode: bar height and width is controlled by postal regulations.
The minimum width for all other codes is 3. These non-Postal codes
proportion thicker bars based on the width you select for the thinnest bar.
Figure 5-22 shows an example of the Code 39 bar code.
If you have a PCL5 printer, barcodes may be rotated, just like any other text.
The COPY function is used to re-access data and copy it to another location
on your form. COPY is entered in the Equation field followed by the
reference number of the original data field. The copied data can then be
reformatted or used in calculations, if desired.
Functions 5-41
Integrated Custom Software, Inc.
Figure 5-22 – The Data Mapper for a bar coded label. The type of bar code
and the height and narrow bar width are selected in the Equation column.
This form definition might produce a label similar to that shown below.
number at the top of the remittance advice portion of the check. COPY is
used twice to place the check number on the top of the check in a different
font, and a second time to place the number in the MICR line at the bottom
of the check.
Mathematical Functions
Where input data is to come from direct data entry or through the use of an
intermediary file FormSprint supports four-function spreadsheet math plus
automatic totals and subtotals. All processing proceeds strictly from left to
right. Parentheses are not supported. Entries in the Equation column consist
Functions 5-42
FormSprint Instructions
Figure 5-24 – The second screen of the manual check form showing several
types of Equation functions.
Functions 5-43
Integrated Custom Software, Inc.
of numbers, references to other data fields, mathematical operators +, -, /,
and * (multiply), format definitions, and several special commands.
If you wanted to multiply the sum of data field 3 and data field 4 by the
number 7, the complete equation would be R3+R4*7. Note that this differs
from conventional algebra because of the left-to-right processing and the
absence of parentheses.
Columns can be totaled by entering TOTAL. The system will add all
numbers that have the same starting (From Left) column position as the
output data field. Entering TOTAL1 for the first level, TOTAL2 for the
second, etc can produce subtotals.
.## Inserts a decimal point and rounds the data to the number of places
indicated by the number of #'s.
The actual sequence of the formatting characters is irrelevant except for the
number of #'s to the right of the decimal point and the location of the 0
immediately to the left of the decimal point.
Note that whenever a numerically formatted definition appears, the data will
be automatically set flush right in the defined output data field, with proper
alignment being obtained with both fixed pitch and proportionally spaced
fonts. This provides automatic decimal point alignment for columns of
numbers. If no format definition appears, the output data begins
immediately at the beginning of the output field (left justified).
Equation examples are shown in Figure 5-24, the second manual check
Data Mapper screen. References 16 and 17 are formatted as numeric
characters with two decimal places [ F(#.##) ].
The equation for Reference 18, TOTAL F($#.##) - totals the Net Amount
column (note left and right edges are the same as for Net Amount) and then
Functions 5-44
FormSprint Instructions
places a $ at the beginning of the output and formats with two decimal
places.
When TOTAL is used, it causes all numbers in data fields with the same
starting and ending positions to be added. Note that wherever TOTAL is
used, the output column position must be exactly the same as that for the
values being totaled, in this case, 170 millimeters left to 200 mm right.
NP - Suppressing Data
The NP function was also used in spool file processing prior to March 1998
to specifically suppress particular spool file lines from printing. Note that
when suppression is used, all positioning parameters must still be
completed.
The TRIM function was used for spool file processing on forms designed
prior to March 1998. The TRIM permitted the selection of a sub-string from
any input spool file line. TRIM is entered on the Equation line followed by the
start column, a forward slash /, and the end column (TRIMss/ee). For
example, entering TRIM1/20 in the Equation field of any reference would
instruct FormSprint to use only columns one through twenty as input. When
used in conjunction with the COPY function, the line can be re-accessed and
either the same or a different TRIM could be used to select the same data or
a different data field from the same line.
Functions 5-45
Integrated Custom Software, Inc.
Functions 5-46
FormSprint Instructions
Distribution enables the user to print any number of copies of any page of a
form to multiple printers simultaneously. When Distributed Printing is used,
FormSprint follows the outq assignments in the Distributed Printing lists
rather than the outq assigned to one of FormSprint's virtual input queues.
Distribution 6-1
Integrated Custom Software, Inc.
(FN(DD,Queue,Qlib,Pageset,Copies,Path,Sort)). Both fixed distribution and
variable distribution options can be used within the same form. Each of
these options will be discussed separately.
Figure 6-2 – F8 from the Printout Default Values screen brings you to the
fixed Distribution Print Selections screen.
Enter the Print Default Values screen of the form definition (F2 from the
Spool or Data Mapper screen - Figure 6-1). Mark the Collate Option with a
"D" for Distribution and press F8 - Distributed Printing Options.
Enter the printer output queues (this is not the FormSprint Virtual Input
Queue, but rather the actual printer outq), enter the proper library, the
number of copies to include, and then mark with an "X" the page or pages to
be included at each printer location. This is all that needs to be done to set-
up distribution. Please note that if you are testing through the FormSprint
Link (FMSTB) interactively, you will need to specifically request distributed
printing on the Link screen. Also, be sure that each of the printers included in
the list can support the same FormSprint print driver.
FormSprint output can also be written to a file. Please see the next section
in this chapter for a discussion of PCL file creation. FormSprint can also
create a PDF or TIF file if you have purchased the add-on PDF/TIF
Conversion Module (please see the end of this chapter for a discussion of
the PDF/TIF file options.
Distribution 6-2
FormSprint Instructions
Distribution can also be used to create separate output spool files in order to
accomplish decollation. This page separation can be done by distributing to
different printers, or by distributing the different pages to the same printer.
For example, as shown in Figure 6-3, the distribution list could include the
OUTQ - PRT01 and select page one of a form. PRT01 would be listed a
second time and a third time, selecting page two of the form and then page
three of the form. The result would be three separate spool files; one
containing all page ones, a second with all page twos and a third with all of
the page threes.
Figure 6-3 – A Distribution Print Selection like this, would result in de-
collating your forms – all of the first copies would be separated from the
second copies and the third copies.
Distribution can be used in conjunction with the alternate tray selection from
the Print Default Values screen (see Chapter 1 - under Print Default Values).
With this implementation, the Original of a form (perhaps an AP check) could
be pulled from Tray 1 where you would load your check stock or perhaps
your expensive pre-printed letterhead, and your copies of the check or other
form which will remain in-house, could be printed on plain paper stock pulled
from a separate tray on the same printer, or printed on a different printer
altogether. By using Distributed Printing with your alternate tray selection,
your output will be sorted with all of the originals together and all of the
copies together.
Distribution 6-3
Integrated Custom Software, Inc.
The first printer in the distribution list will be started during FormSprint
merge processing. The remainder will not be started until all FormSprint
merge processing has been completed for the first printer. For large jobs,
therefore, the location with the most immediate need for the output should
be placed at the top of the list of output locations. However, very little
processing is required to prepare the output for the remaining locations and
printing at all of these locations will begin almost immediately after merge
processing has been completed.
FormSprint can produce a data file containing the complete PCL print file
for transfer to other devices for remote printing, viewing or fax processing.
The file is created using the distributed print function, accessed by pressing
F2=Print Default Values from the Spool Mapper or Data Mapper screen of
the form definition followed by F8=Distributed Printing. To obtain PCL file
output, enter the library where the output is to be placed in the column
labeled Library, enter 1 in the Copies column, and enter *FILE in the column
labeled Special Processing. Then place X’s in the remaining columns to
select the form pages to be included in the file. FormSprint output can also
be written to a PCL file rather than to a printer. If you wish to output the PCL
directly to a shared folder, enter the folder path beginning with / followed by
the folder name – for example, /ICSTRANS. Enter 1 for the number of
copies and put an X under the desired form pages to include. The system
will assign a unique file name with extension PCL or you can enter your own
file name in the “Queue or File” field. Note, however, your file must have a
valid name (no more than 6 characters beginning with an alpha character –
not including the extension) and if the file already exists in the folder, it will
be overwritten. This example of distributing to a file directly into a folder is
shown in Figure 6-4.
If the PCL file is placed in a specified library, the library must exist prior to
running the program. If the variable input source is a spool file, the name of
the output file can be entered in the USERDATA field on the spool file
preceded by ‘&F’. For other variable input sources or if the ‘&F’ coding is not
found in the USERDATA field, and the user has not assigned a name, the
file will be named with the letter F followed by a numeric code. The file
description will contain the name of the form used to generate the file. The
file is formatted as a series of 132-character records containing ASCII PCL
code.
When FormSprint jobs process through the Batch Job Controller, with
Distributed Printing selected, FormSprint ignores the Printer Output Queue
established in the batch job parameters of the Job Controller. However, if the
user wishes for the distribution to be linked to the batch job assigned printer,
enter the output queue on the Distributed Printing Options screen as
*QUEUE, this will cause FormSprint to use the batch job assigned printer
Distribution 6-4
FormSprint Instructions
wherever it encounters *QUEUE. (see Figure 6-5) Wherever *QUEUE is
used, no entry for the library is required.
Figure 6-4 – You have the option to create a PCL, TIF or PDF file when
using the Distributed Printing Options screen.
Figure 6-5 – *QUEUE for the OUTQ links distribution to the Batch Job.
Distribution 6-5
Integrated Custom Software, Inc.
With some application programs, a page may be generated as the first page
or two of a spool print file which you do not wish to print. In your form
definition, create a page one (both in the flash and variable portions of your
form) to take the data from the first page of your spool file. Enter the Print
Default Values screen of your form definition, mark Collate = D for
distribution and change the Form Re-use start page to page two (or three or
four, depending on how many pages you are attempting to eliminate). The
Print Default screen for this example is shown in Figure 6-6. Now press F8 -
Distributed Printing Options and mark only those pages you wish to print.
For example, suppose your program outputs one header page on all Invoice
print runs - and you do not wish to print this header page. Your Invoice form
contains an Original Invoice and a Copy to be kept in-house. Create a three-
page form - page one simply takes all lines from the first record of the spool
file. Page two is the Original Invoice and Page three is the Invoice Copy. Go
to the Print Default Values screen (F2 from the Spool or Data Mapper
screens). Make the form Re-use start page = Page 2 (the Original Invoice).
Next, mark Collate = D and press F8 - Distributed Printing Options. Enter an
outq or *QUEUE and mark page 2 with an "X", enter a second outq or
*QUEUE a second time and mark page 3 with an "X". The Distributed Print
Distribution 6-6
FormSprint Instructions
screen would look like the screen shown in Figure 6-7. The results - no page
one, all Original Invoices in one pile and all Invoice Copies in a separate pile.
Using Variable Distributed Printing can also eliminate selective pages by
testing some field or fields within the data. Continue to the next section for
information on Variable Distributed Printing.
Figure 6-7 – To eliminate the header page, do not include page one in your
Distributed Print Selections screen.
FormSprint provides a function for sorting spool files and distributing the
resulting sorted pages to any desired AS/400 addressable laser printer.
Sorts are made on the basis of spool file data on either a specific page basis
or on the basis of sets of pages constituting a form set. For example, three-
page purchase orders could be sorted on the basis of the PO number, which
might only appear on the first page. Alternatively, single-page order
acknowledgements could be distributed to select printers on the basis of the
salesman name.
Distribution 6-7
Integrated Custom Software, Inc.
ICSPROG/DISTABLE. The data resides in the file ICSFDATA/DISTABLE in
multiple members named with the table names.
Figure 6-8 shows the first Distribution Table Editor screen. Create the table
by entering Option 1 - Create and a name for the table - press ENTER. To
begin building the table, enter Option 6 - Add Records next to the table and
press ENTER, the screen shown in Figure 6-9 will be displayed. Enter the
value to be tested from the spool file, exactly as it would appear in the spool
file (space and case sensitive). Next enter the output queue and library to be
used if there is a match to data found in the spool file - for example, if we are
looking for Purchasing Agent names and the name is JONES - the output
queue might be JONESQ. Now enter either SET or PAGE to indicate if all
pages of the form are to be included or PAGE if only the page being tested
is to be included. Finally, enter the number of copies to be included. Press
ENTER to continue building the table, press F3 to Save and Exit or F12 to
Save and Return.
The Distribution Table has an optional security control feature. Access the
security control with Option 14 for the specific table to be controlled. The first
entry in this program (Figure 6-10) is the public access security level. All
users not specifically listed will have the security access defined for the
public. If an individual user profile is listed, the security level for the individual
will prevail, and may be higher or lower than the public access level.
Distribution 6-8
FormSprint Instructions
Figure 6-10 – Each table has its own security screen, access with Option 14.
Distribution 6-9
Integrated Custom Software, Inc.
Three levels of security are available: S=full access and security control,
E=edit and display rights but no access to the security table, and N=no
access. The default security level is S for public access to the tables.
When the Variable Distributed Print function is invoked on either the Spool
Mapper Fonts and Functions screen or on the Data Mapper screen,
FormSprint looks up the value from the spool file in the DISTABLE
directory. If the spool file value is not found, FormSprint checks to see if a
default output queue designated by a key value of ELSE is in the
DISTABLE. If an ELSE entry has been made, the page or page set will be
tagged for distribution to the output queue designated in the ELSE record.
The spool file is then printed in spool file/output queue order. All records for
a given output queue are printed from a single spool file and records
selected using the ELSE function will be sorted by the spool file selection
value.
The Variable Distributed Print function is entered in the Spool Mapper Fonts
and Functions screen or the Data Mapper Equation column. The value to be
looked up should be entered as a reference on the Spool Mapper with the
Input line and column designations marking the exact placement of the data
in the spool file. With the Data Mapper, TRIM and COPY would designate
the text. The function call is of the form:
A final step in implementing this function is to enter the Print Default Values
screen for your form and mark Collate = D for distribution.
Variable Distributed Print can also be used to prohibit pages from printing.
Unlike Fixed Distribution, as discussed above, this method can select
records for printing or elimination on the basis of data in a field or fields
within the data stream. For example, perhaps certain customers do not
require a paper copy of their invoice and printing them is simply wasting your
paper and toner. Can you identify these customers by their customer
Distribution 6-10
FormSprint Instructions
number, or perhaps a prefix on the Invoice number or some other reliable
criterion?
Let’s say that the prefix “NP” on the Invoice numbers (line 10 col. 20 to 27)
designates a customer for whom we do not want to print an invoice. Begin
by selecting a buffer that will become our “switch” to turn printing on or off.
Now select a field in your spool file that always appears – for example, the
date field, which for our example we will say, is in line one position 70 to 77.
Make an entry on your Spool Mapper screen as shown in Figure 6-12a, line
one. Press ENTER and use the example in Figure 6-12b to load an X in
buffer 1 (doesn’t have to be buffer 1). Buffer number 1 now looks like this:
X03/15/00 – that is, the letter X loaded to the front of the date from line one
of our spool file. The date is irrelevant in our attempt to prohibit certain
pages from printing; this was simply our method of pre-loading a character in
the buffer that will be used to switch printing on or off.
Next make another entry in your Spool Mapper in which you enter the line
and columns where the Invoice Number will be found (reference 2 in Figure
6-12a). Press ENTER and in the Special Function field enter:
FN(PI,”NP”,20,21,20,20) and follow the coding in Figure 6-13 to Replace the
contents of buffer 1 with the N. At this point, buffer one will contain either the
X for printing or an N for no printing.
Distribution 6-11
Integrated Custom Software, Inc.
Figure 6-12a – Reference 1 uses the date field to load a code (X) to the
buffer. The X will become a “switch” for distribution.
Distribution 6-12
FormSprint Instructions
Figure 6-13 – The “Print If” is used to determine if this invoice is not to be
printed. If the NP text appears, the buffer is REPLACED with the letter N.
The last step within the form is to use buffer 1 as input (reference 4 Figure 6-
12a) to the call for the Variable Distributed print function. The Fonts and
Functions screen for this entry will simply have the Special Function:
FN(DP,PRINTIT) where PRINTIT is the name of our table. The table itself,
will have only one entry: Input value is X and then an entry for the Output
queue or *QUEUE, the library, set (or page) and copies = 1. The X was
preloaded using the date field, then, the first position became an N if our non
printing customers were found and since N is not in our table, these records
which contain N as the first column in buffer 1 will not print.
Queue is the output queue or file name if a PCL, PDF, or TIF file is to be
produced (see the end of this chapter for more on the PDF/TIF Conversion
Distribution 6-13
Integrated Custom Software, Inc.
Module). *QUEUE is supported to link the printing to the printer associated
with the Virtual Queue being used.
Path is the folder path, beginning with a forward slash / if file output to a
folder is desired.
Sort is either Y or N and selects sorting or no sorting based on the spool file
input identified by the spool mapper input parameters.
Any of the parameters after the queue library may be omitted. If omitted,
Pageset defaults to PAGE, Copies defaults to 1, Path defaults to blank, and
Sort defaults to Y (yes). If you are using PCL, PDF, or TIF file creation, the
Qlib may also be omitted but the comma should be included.
Note that as with all distributed print functions, the Collate parameter on the
Print Default Values screen must be set to D (see Chapter 1) and the
parameter to allow distributed printing must be set to Y is using the
FormSprint Link Interactive processor (see Chapter 18).
Sorting
Records selected using the ELSE default output queue designation are
sorted by the spool file selection value. Therefore, if the value being looked
up in the table is the Purchasing Agent's name, those records selected for
the default output queue (ELSE) will be sorted in alphabetical order by
agent's name. If the value being looked up is the employee number, the
Distribution 6-14
FormSprint Instructions
Figure 6-14a – Sample spool file showing the store # in columns 53-55.
Figure 6-14b – Reference 2 in this example takes the store number and
loads it to a buffer.
Distribution 6-15
Integrated Custom Software, Inc.
Figure 6-14c – As the store number is loaded to the buffer, the letters “PRT”
are loaded in front and the “L” is loaded behind – creating an output queue
name for the store – PRT105L.
records selected for the default output queue will be in employee number
order. The order of the sort will follow the AS/400 sorting protocol. Therefore,
the Distributed Printing/Sorting Function can be used to re-sort your spool
file even if you are not distributing your printout. Also, different pages of the
form can be sorted in different ways depending upon what field is selected in
the input parameters.
You can also implement the sort in the same manner used for any variable
distribution, establish the table, enter only one record into the table with input
value of ELSE (see Figure 6-15), if you are not also distributing. The output
queue could be entered as *QUEUE and library as *LIB to print to the batch
job associated printer, or you could enter an actual output queue and library.
Next enter PAGE or SET (depending on whether you want only the page
being processed to be included - PAGE or the entire form – SET) and copies
= 1. In the form definition Spool Mapper or Data Mapper screen, enter a
reference which points at the field being sorted (Input line and column
Distribution 6-16
FormSprint Instructions
Figure 6-15 – One way to sort the spool file, is to use the field to be sorted
as input and the Variable Distribution Table with an entry of “ELSE”.
NOTE: this function can be called more than once in the variable definition
permitting simultaneous distribution and sorting with a single print file. In
addition, the fixed distribution list (F8 from the Print Default Values screen)
and variable distribution can be used together. Therefore, you could have
one distribution list which is always followed and additional distribution can
become dynamic based on the spool file input data.
Also note that the input to this function does not necessarily need to be a
field from your input spool file. You might want to create a new sort criterion
based on a field from the spool file (like an Invoice Number, or perhaps an
Employee Number) plus some other field or a literal, which you could
concatenate with the first field by using the buffers. For example, perhaps
you would like to re-sort a payroll check file by department followed by
employee number. Begin by putting the employee’s department number in
the front of a buffer (see Figure 6-18), now take the employee number and
add to the end of the same buffer (Figure 6-19). The buffer now becomes
Distribution 6-17
Integrated Custom Software, Inc.
Figure 6-17- The spool mapper for a paycheck in which the concatenation of
the department (step 2) and employee # (step 3) become the new sort
criteria.
Distribution 6-18
FormSprint Instructions
Figure 6-19 – The Employee number is added to the back of the same
buffer.
Distribution 6-19
Integrated Custom Software, Inc.
the input to your sort (make sure your start/end columns accommodate the
entire length of your new field). The maximum size of the field used for
sorting is 40 characters. Step 11 in Figure 6-17 shows the Spool Mapper
reference to be used for Distributed Printing. Remember that ANY type of
distribution must be activated by selecting D for Distribution on the Printout
Default Values screen.
Here is another common scenario: we want all of the Original invoices for
any one invoice to print first, followed by the Copies of that invoice, followed
by the next Original and its copy. This is a sorting problem. The screens
shown in Figures 6-20a,b, c, and d illustrate one solution to this request. The
Invoice number is first loaded into a buffer with the number 1 added in back
(1 for the form page – the Original). Next, we add the invoice page number
from the spool file to the end of the same buffer. This same procedure is
repeated to a second buffer but this time, form page 2 is added to the back
of the invoice number (form page 2 is the Copy). Then, each page has a
reference for distribution, page one – the Original – is distributed from the
first buffer and page two – the Copy – is distributed from the second buffer.
Figure 6-23d shows the dynamic distribution function used for this type of a
sort.
Figure 6-20a – In this example, the originals for any single or multiple page
invoice will print, followed by the copies for that invoice, followed by the
originals and copies of the next invoice etc.
Distribution 6-20
FormSprint Instructions
Figure 6-20b – The invoice number is added to the buffer and the number
“1” (form page – the Original) is added behind.
Figure 6-20c – The invoice number and “2” are added to a different buffer.
Distribution 6-21
Integrated Custom Software, Inc.
Figure 6-20d – Dynamic distribution is used from both buffer 1 and buffer 2
for the sort of the form pages.
From the FormSprint spool mapper or data mapper, press Function Key 2
for the Printout Default Values screen. Change the Collate option to D for
distributed printing, and then press Function Key 8 for the fixed distributed
printing screen.
In the column headed Queue or File, enter the desired output file name with
an extension of either .PDF or .TIF depending on the type of file desired.
The file name is limited to six characters (not including the extension)
beginning with an alpha character. You can enter only the .PDF or .TIF
without a file name if you want FormSprint to create a unique file name. The
library column can be left blank. In the Special processing or folder path
column, enter the folder path beginning with a /. Enter 1 for the number of
copies and then check off which form pages you want to include. Figure 6-21
illustrates this method of selecting PDF/TIF file output.
Distribution 6-22
FormSprint Instructions
Figure 6-21 – The Fixed Distribution Print Selections screen provides one
method for creating the PDF or TIF files.
Also, the dynamic distribution function may be used to load the file name or
just the extension from the spool file directly or from a buffer or memory
location (see the example in Figure 6-23).
The user may also produce a PDF/TIF file directly from the flash printout
screen. Press Function Key 15 from any of the flash screen and enter a file
name with an extension of either PDF or TIF in the Queue field, and enter
the folder name beginning with a / in the output queue library field.
Distribution 6-23
Integrated Custom Software, Inc.
Figure 6-22 – The Distribution Table can be used for creating PDF/TIF files.
Entering only the extension in the OUTQ field results in a system assigned
file name.
Distribution 6-24
FormSprint Instructions
Chapter 19
Getting Ready to Go into Production
The FormSprint Job Controller (ICSPROG/FMSTCTL) (Figure 19-1) permits
the user to establish the working parameters for the ICS virtual input queues.
The Job Controller is discussed in detail in Chapter 18. The job descriptions
created by the Job Controller are used to create the batch jobs for running
FormSprint in subsystem ICSFMST in library ICSSYS. Use the Job
Controller to create new jobs, change existing jobs (you can scroll to any job
by batch number or virtual input queue name), or delete existing job
descriptions. You can start the subsystem with a Function Key 15 from the
Job Controller or end the subsystem with a Function Key 18 from the Job
Controller. However, when testing is complete, and you are ready to go into
production, you will want to automate FormSprint processing.
Figure 19-1 – The ICS subsystem must be set-up by making entries in the
Job Controller. Then, the subsystem and jobs must be started.
Getting Ready 19 - 1
Integrated Custom Software, Inc.
defaults except for the request data which would be: STRSBS
SBSD(ICSSYS/ICSFMST) (Figure 19-3). Alternatively, a program with
multiple commands could be called at this location.
When started interactively from the Job Controller, FormSprint jobs run
under the user profile of the interactive user. When started with the
subsystem, the jobs run under the user profile QUSER. Modifying the job
description ICSSYS/FMSTJD can change this selection. In all cases, the
user profile maximum allowed storage parameter must be set to *NOMAX or
large print runs will be truncated.
Other Considerations
When the ICS subsystem and jobs are set to start automatically, the next
step is to ensure that the application spool files are being directed to the
virtual input queues (remember that this is the OUTQ parameter on your
spool files, not the printer).
Check to make sure that the FORMTYPE parameters on your spool files
match your form definitions, or that the proper overrides have been
implemented. You can use the re-name function in the FormSprint Editor if
your spool files already have unique FORMTYPES and the form has been
defined with a different name. Access the re-name function by selecting
Option 1 from the ICSMENU, Function Key 3 to Edit a Form Definition and
then position the cursor on your form and press Function Key 7. You will be
given a screen for renaming the form. Remember that FORMTYPES are
both case and space sensitive.
If you will be using an intermediary file, make sure that either the queue
check interval has been set in the batch job parameters, or that the CL is in
place to issue a 'wake-up’ call after the program creates the intermediary file.
Check the Job Scheduling parameter on your printer file definitions. Jobs
being submitted for FormSprint processing should be set to *FILEEND and
not *IMMED. If a spool file comes into a FormSprint virtual input queue in
ready status but is still being written, FormSprint will be unable to continue
processing and will put the spool file back on HOLD. If you are having a job-
scheduling problem, you might observe that sometimes your jobs are not
processed and the spool files are put back on HOLD. What is occurring is
that sometimes the files are complete and in RDY status when FormSprint
processing is initiated, and the files process properly. At other times, your
system may be a bit slower or the files larger and FormSprint cannot
access the files when it’s ready to process, so FormSprint puts them on
HOLD.
Getting Ready 19 - 2
FormSprint Instructions
Getting Ready 19 - 3
Integrated Custom Software, Inc.
Figure 19-4 – After creating the startup job, add an Autostart Job Entry to
fully automate the starting of the ICS subsystem.
Printers
The printers used for FormSprint processing must be PCL capable laser
printers. The easiest method for setting-up the printer on the AS/400, is to
use the CRTOUTQ command and TCP/IP. Follow each of the screens at the
end of this chapter for the proper selections to complete your output queue
set-up.
The default run priority for remote writers is 50. The normal run priority for an
AS/400 writer is 15. Therefore, you may want to change your TCP/IP printer
writers. Enter the WRKCLS command as shown in Figure 19-9. Change the
run priority to 15.
Timing
Finally, check your printer for timeout settings. Laser printers are designed to
accommodate PC environments where they may receive incomplete print
files. Therefore the printers have timers so they automatically reset if no data
is received within a specified interval. The timers generally default to about 5
to 10 seconds.
Getting Ready 19 - 4
FormSprint Instructions
In a shared computer environment such as the AS/400, this can create a
problem if the transmission of data to the printer is interrupted while the
computer services other jobs. If the printer waits longer than the timeout
setting, it performs its reset and the subsequent pages will print in the wrong
format without the flash definition.
Printers attached to the AS/400 should therefore have their timers either
disabled or set to large values. Printing the configuration of the printer using
the printer panel controls will reveal the location of the timer settings. These
should then be set to 0 to disable if the printer permits or set to values of
several minutes.
Tray Set-up
If your jobs require pulling paper from different trays, you will also need to
check your printer configuration to see if the trays are linked. Linking is
desirable when you have only plain white 8 ½” X 11” paper in all drawers
and you want the printer to begin pulling from another drawer if it runs out of
paper. However, if you have special paper in any one drawer, you will need
to disable the linking. On many HP printers, the trays can be “un-linked”
simply by defining different paper types for the various trays. You will need
to consult your printer documentation for specific instructions.
Figure 19-5 – Use the CRTOUTQ command and the parameters shown to
set-up a TCPIP output queue.
Getting Ready 19 - 5
Integrated Custom Software, Inc.
Getting Ready 19 - 6
FormSprint Instructions
Figure 19-8 – The final screen of the CRTOUTQ command – press ENTER
to complete the definition.
Figure 19-9 – The priority for remote writers defaults to 50 – you may want to
adjust this to a higher priority (the other writers are 15).
Getting Ready 19 - 7
Integrated Custom Software, Inc.
Getting Ready 19 - 8
FormSprint Instructions
Appendix A
Program File Listing
The following files are shipped with FormSprint. These files should all be
on the same volume.
File Description
CHECKNUM Check Number ref. file editor screen layout definition file
CHECKNUM2 Check Number ref. file editor screen parameter definition file
A-1
Integrated Custom Software, Inc.
File Description
A-2
FormSprint Instructions
FOLDERS
A-3
Integrated Custom Software, Inc.
Appendix B
Data File Listing
FormSprint uses or creates the following files:
A-4
FormSprint Instructions
A-5
Integrated Custom Software, Inc.
Appendix C
Preferred Postal Bar Code Placement
A-6
FormSprint Instructions
A-7
Integrated Custom Software, Inc.
Internal Scalable Fonts (cont.)
A-8