The topics covered in previous episode of technical tips are:
- InterForm400: The best Auto Forms Control setup
- InterForm400: How to overrule AFC templates
- InterForm400: Tesla QR barcode requirements
- Eliminate your manual processes with InterForm
- InterForm400: How to create PDF/A files
- InterForm400: How to create unicode output
- Merge PDF files with AdvancedPDF
- Designs depending on dates
- How to edit a spooled file
1. InterForm400: The best Auto Forms Control setup
Most are probably already aware of this, but I would still like to make it known to all, how you should consider to setup Auto Forms Control. The tip is to use a template: Insert all of the common rules for one output queue, and reuse this as a reference for all your printers. The advantages are simple and clear:
- You need only to setup the common rules once
- It is easier to make changes for the future for all your printers
- The risk of defining something wrong is smaller, as you need only to insert the rules once
- It is very easy to setup a substitute of a printer if one printer stops to work – just redirect the spooled files to another printer, that use the same template
You can even use the same template for both color and black/white printers – as the printer type is specified on the individual output queues.
Best Auto Forms Control Setup
This video shows how to define and use a template in Auto Forms Control: See video here - 04:50 min.
2. InterForm400: How to overrule AFC templates
Even though most customers know the use of Auto Forms Control (AFC) templates (as mentioned above), there are still many, that do not know a special way to keep flexibility, while using an AFC template.
It is actually possible to ‘overrule’ the common rules/functions in a template. This can be used, if you want to use most of the common definitions in a template, but for one or more spooled files you might want to deviate from the normal processing on specific printers. That can e.g. be used in these scenarios:
- On one specific printer you want to merge a special spooled file with another overlay than normally, to include or exclude information compared to the normal contents
- You want e.g. to make sure, that spooled files on a specific output queue are not archived – e.g. because this output queue is used for reprinting from an archive (where spooled files are stored)
- One printer is required to print an extra copy for the customer – unlike any other printer in the company
One printer is ‘authorized’ to print special output e.g. cheques (unlike any other printer), but still it should also be able to handle normal spooled files as any other printer.
How to overrule AFC Template definitions
The trick for overruling is described in this video: See video here - 04:19 min.
3. InterForm400: Tesla QR barcode requirements
Tesla is requiring suppliers to use labels with very large QR barcodes – actually up to 3.2 Inches wide and high. That is normally not possible to print on a Zebra printer (limitation of the ZPL printer language), but that is still possible with InterForm400.
How to create large QR barcodes for Tesla on Zebra printers
This video includes the prerequisites and shows how to define and use such a barcode font: See video here - 02:37 min.
4. Eliminate your manual processes with InterForm400
The great advantage of using InterForm products is the ability to replace manual processes with automated workflow and intelligent routines.
E.g. when sending your customer invoices, account statements, reminders etc. The customer would often expect to receive other specific and related documentation or files to be included in the same email.
Without automated processes, you would manually have to search your archives or customer accounts, to find all the necessary files and attach them individually – A task that easily takes 10-20 min. per account.
With InterForm, a few smart routines are added to a workflow and the whole process is fully automated. InterForm is even able to automatically embed the files and documents into a single PDF before emailing it to the customer.
If you want to learn more about automated processes with InterForm, feel free to contact us here.
5. InterForm400: How to create PDF/A files
The PDF/A files is quite interesting for those that consider long term archiving. InterForm can of course help you with that. To help you get started, we have created a couple of videos:
Create PDF/A files - in short
This video is a short demonstration of how to setup and create PDF/A files with InterForm400 on the IBM I. See video here - 04:34 min.
A detailed video with an explanation of PDF/A can be found here - 12:30 min.
6. InterForm400: How to create unicode output
InterForm400 can create unicode output. With unicode output we mean that you can output from/to any codepage, that you can think of. It also means, that you can combine fixed texts in any EBCDIC codepage in the same output.
How to enable unicode output
For InterForm400, PDF/A and unicode output is two sides of the same coin, so I could not hold back this video after creating the new, short PDF/A video above. See video here - 06:48 min.
7. Merge PDF files with AdvancedPDF
Many InterForm customers have started to merge PDF files when distributing e.g. standard invoices, account statements and reminder notifications to their customers.
Merging PDF's ensures that the end-customer receives all the information they need, in one single PDF file. This can be both timesaving for you, and a better service for your customers. See an example of a merged PDF document
PDF merge is available with our AdvancedPDF module - Available for both InterForm400 and InterFormNG
- Merge as many PDF files you want
- Structure the document as you wish
- Add bookmarks in the PDF for a complete overview for the receiver
- And much more
8. Designs depending on dates
Do you want a greeting or message to your customers? Does your company plan to change the address, bank account or anything else, that you would like to tell your customers? Do you want to insert a special add in your output, that is only shown within a specific date interval? If you can say Yes to any of these questions, then you should watch the videos below. It explains exactly how extra contents can be added temporarily to your output (and automatically disappear again after a certain date).
See video here - 03:35 min.
9. How to edit a spooled file
Normally it is impossible to edit a spooled file, but InterForm400 includes a simple command to help you to do exactly that. It is a simple editor, where you can copy, delete and edit the spooled file exactly as you please. I refer to the command, APF3812/APFEDTPRT, which is described in the following video.
See video here - 02:58 min.
The topics covered in the last episode of technical tips are:
- InterForm400 Cookbook: Merge to an output queue found in spooled file
- InterForm400: Extend spooled files with Split definitions and the Pagebuilder
- InterForm400: How dynamic do you want your emails and documents to be?
- InterForm400: Support for larger QR barcodes in ZPL.
- New PTFs for InterForm400 – version 2017M05
1. InterForm400 Cookbook: Merge to an output queue found in spooled file
I received a question from a business partner the other day: Is it possible to retrieve an output queue written inside an input spooled file, merge the spooled file with an overlay (or overlay selector), and then place the merged spooled file on that very output queue, that is specified inside the input spooled file?
The answer is yes. There are even 3 possibilities for getting to such a setup. The one to use depends on various tradeoffs, so I have chosen to include descriptions of the 3 solutions and list the pros and cons for each in the cookbook. That should help you to select the right solution for you if needed.
The updated cookbook can be downloaded via this link:
2. InterForm400: Extend spooled files with Split definitions and the Pagebuilder
There is no end to the requirements for additional, dynamic contents of the output from InterForm400. In InterForm400 such contents (normally) need to be based on information found in the input spooled file. So often we will need to add extra information to a spooled file prior to a merge. The two options available in InterForm400 to add information are the Split definition and the Create PageBuilder Spooled file command, CRTPBSPLF.
Both the split definition and the CRTPBSPLF command can e.g. use SQL or similar to grab additional information from databases, and add that to a new spooled file, for further processing.
You are normally restricted by the original spooled file size (height and width), when these functions are called, but it is actually possible to extend the new spooled file to e.g. the maximum size of a height of 255 lines and a width of 378 positions. In this way, you can create more than enough space for any variable, that you might want to use (The email finish definition can e.g. use up to 99 variables, and the PDF file naming can use up to 34 variables) and add to the new spooled file for processing e.g. in an email finish definition.
The split definition
For the split definition we can specify the new size directly on the split definition here:
The Create PageBuilder Spooled file command, CRTPBSPLF
With the 2017 Versions of InterForm400 you have a new parameter on the CRTPBSPLF command, PAGESIZE, where we can also extend the new spooled file:
With the changes described above, there should be more than enough space to add any extra information, that your heart desires. That can be used as a basis for the next topic below.
3. InterForm400: How dynamic do you want your emails and attached documents to be?
Email communication is getting more and more important. We hear the request for additional flexibility, when it comes to the contents of the emails, that are sent out (with attached business documents).
For the InterForm400 part, we have been mainly been helping customers to get the best possible design in the attached documents. An important part is however also the contents of the email itself (apart from the attached files).
As you probably know, InterForm400 support html files, that can specify the contents of the email. The html files can use images - either embedded in the html as Base64 or via a link. When you setup the contents of your email, you can of course use variables in a simple text, but you can also use variables in a html file, that is referenced in InterForm400, so that the email can be personal and refer to the name of the recipient, a purchased product and other dynamic information, that we have taken from the input spooled file.
But some customers wants to use InterForm400 to bring them one step up, and make the email even more dynamic, and e.g. include dynamic pictures of the contact person for this specific customer. They also want to include special offerings, that are ‘handmade’ especially for this customer. These special offerings could be based on special information, that is known for each specific customer:
- If e.g. it is known, that the customer e.g. has a child, that is almost 18 years, then it might be interesting to include special offerings for products, that such a person would be interested in e.g. cars, driving schools, insurances, small flats in the area etc.
- If the customer normally pays the invoices quite late, you can e.g. include information of how to split up purchases into smaller payments.
- Perhaps the customer have bought products, that can be combined with other products, so of course the customer should be informed of these additional products.
- Include a special voucher code, if the customer have bought for a larger amount.
Examples of how to make the email contents very flexible:
- Use variables in the html for texts to e.g. address the customer by his/her name, product names and references.
- In the email finishing definition you can use variables as a part of the path, that refers to the specific html file. In this way you e.g. let the customer type point to the html file, that should be used for this specific customer.
- Use variables as a part of the path (and/or name) of images in the html file, that you are using. In this way it is easy to refer to a special ‘offer of the week’, or include an image of the contact person (in your company), that has created the included document.
- The html file can include links, that are also built up dynamically with variables to include e.g. a link for payment, or a special link that refers to the manual of the product, that the customer has just bought.
- The subject of the email can of course also include variables.
- If you call a user program from the email finish definition, then this program can also read the variables, and from the values e.g. return a specific text version to be used.
Examples of how to make the attachment(s) of the email flexible:
- You can include an extra, optional attachment in the email. The path to this extra file can be a path, where variables are included. The variables used can be a unique path, if you e.g. decide to build this extra file at runtime, then you can include a unique key value as a variable.
- You can use variables in the name of the PDF file, that is included to e.g. include the invoice number as a part of the file name, so the attached file can e.g. be Invoice_MyCompany_12345.pdf
- The attached PDF file can also have some special, variable images. These images can be included via a special &&IMG command inside the input spooled file. That command can e.g. be built up via the CRTPBSPLF command. Images included via &&IMG does not need to be installed in InterForm400, but can be images found anywhere in the IFS, or even on another server.
- The attached PDF file can include dynamic links. Such links are added via the &&URI command. The &&URI command should include the complete link, but it can also include a text to display, so that you will not need to display a long, complicated link, but just e.g. a link with the text <Click here>.
The &&IMG and the &&URI commands are covered in the InterForm400 manual in Appendix H.
So in short: There is hardly any limit to how adaptable your emails and documents can be.
4. InterForm400: Support for larger QR barcodes in ZPL.
Zebra (ZPL compatible) printers normally have a limit of 10 dots, when it comes to the module size of QR barcodes. That means, that there is a limit to how large the printed QR barcodes can be, but recently we have seen requests to print much larger QR barcodes.
That is in PDF and PCL not a problem in any old version of InterForm400, but if you want to print really large QR barcodes on Zebra, then you need to upgrade to a 2017 version of InterForm400. We recommend the latest 2017M05 version.
If you have an InterForm400 version in the range 2017M01 – 2017M04, then you can extend the range of the QR barcode sizes, if you install this PTF:
PTF 5225: QR barcode are now supported.
http://download.interform400.com/shares/PTFs/APF5225.ZIP
The procedure to install a PTF is included in the topic below.
Similar support for larger QR barcodes in InterFormNG is also on its way.
5. New PTFs for InterForm400 version 2017M05
If you consider to upgrade to a 2017 version, then you should always upgrade to the latest official version. This is currently version 2017M05. We have issued these PTFs for 2017M05:
PTF 5202: Maillog Group PTF.
Apache HTTP server serving Maillog are not started and the www-folder is not restored.
http://download.interform400.com/shares/PTFs/APF5202.ZIP
PTF 5226: Wrong rotation barcode in PDF.
Barcodes from a remap window in main overlay can be wrong, if there is remap windows in a conditioned overlay.
http://download.interform400.com/shares/PTFs/APF5226.ZIP
You load PTFs by copying the zip files to the IFS in /APF3812Home/PTFs and install them via the InterForm400 menu option:
12. Service functions
50. Apply PTF from the /APF3812Home/PTFs directory
Here you select the PTF number e.g. 5210 and press Enter and F10 to confirm the installation.
(You do not need to unzip the files).
PTFs must always be installed in numeric (ascending) order.
The topics covered in the last episode of technical tips are:
- InterForm400: How to insert special characters in the barcodes
- PTF for InterForm400 – version 2017M04
- Tricks for Swiftview
- New videos: How to create InterForm400 output in Cyrillic and Codepage 870/1153
1. InterForm400: How to insert special characters in the barcodes
The usual challenge is to add these special characters in a 2D barcode e.g. PDF417, QR or Datamatrix. For all of these barcodes you have a special setting to tell InterForm400 to look for a special ‘trigger character’ (Hex byte prefix), which signals, that the 2 next characters are actually the hex code of the ASCII character, that you want to insert. This special, hex byte prefix is set on the 2D barcode font numbers:
If you e.g. state that the Hex byte prefix is ‘^’, and you then remap this spooled file data into a barcode: ‘abc_^66_def’, then InterForm400 will convert ^66 into ‘f’ thus including the text ‘abc_f_def’ in the final barcode.
The easiest way to combine these special characters with data from the spooled file is via the concat element. That can insert the same data like so:
2. PTF for InterForm400 version 2017M04
When you upgrade to version 2017, which is currently version 2017M04. We have issued this PTF :
PTF 5202: Maillog Group PTF
Apache HTTP server serving Maillog are not started and the www-folder is not restored.
http://download.interform400.com/shares/PTFs/APF5202.ZIP
You load PTFs by copying the zip files to the IFS in /APF3812Home/PTFs and install them via the InterForm400 menu option:
12. Service functions
50. Apply PTF from the /APF3812Home/PTFs directory
Here you select the PTF number e.g. 5210 and press Enter and F10 to confirm the installation.
(You do not need to unzip the files).
PTFs must always be installed in numeric (ascending) order.
3. Tricks for Swiftview
Swiftview is an application, that comes for free with each installation of InterForm400. Its main feature is, that it is able to graphically display a PCL print data stream, but it can also be used more widely. In a normal (production) installation, Swiftview is limited to one (named) user profile, but it is possible to purchase Swiftview packages, so that even more (or all) users can use Swiftview.
Below I will name a few places, where Swiftview can help you:
- PCL preview from the graphical designer and the Green screen designer: View the print result without printing anything at all. Most customers are using a PDF preview instead, as this normally is VERY close to the PCL result.
- Graphical view of a merged PCL spooled file: With the commands, APF3812/APFWRKOUTQ and APF3812/APFWRKSPLF you can with option 5 display the contents of a merged spooled file. Option 5 will open up Swiftview if it is a *USERASCII spooled file generated by InterForm400.
- Graphical view of any .prn file (e.g. from InterFormNG) containing PCL5. If you have access to both InterForm400 and InterFormNG, then you can e.g. start up Swiftview from InterForm400, but then you can click the ‘Open’ option and e.g. select a .prn file, that was actually generated by InterFormNG. In InterFormNG you can chose to generate .prn files in the printer setup, causing PCL files to (as default) be saved in C:\ProgramData\InterFormNG\print_outbox.
- Print a PCL file to any even non-PCL printers. When you have opened a PCL file you can select any printer on your PC and select ‘Print method = Windows print’, to use the Windows print driver instead of sending PCL.
- Print only a range of pages of a merged spooled file. In Swiftview you can even chose to print only a range of the pages instead of printing them all. The pagerange option is not an option on the IBM i for the *USERASCII spooled files.
- Convert a PCL file into TIF. After you have opened a PCL file you can select ‘Convert’ and then you can chose to save only an area, the complete page or even multiple pages into a TIFF file. Various TIFF formats are available. It can be useful as a way to create high-quality TIFF files for usage in InterForm400.
- Open other files e.g. TIFF files. You can also chose ‘Open’ to open other file types e.g. TIFF files.
The named Swiftview user(s) can be set via the InterForm400 menu options:
70. Configuration and licences
51. SwiftView Users
4. New videos: How to create InterForm400 output in Cyrillic and Codepage 870/1153
From time to time we are asked about how to print in non-western codepages, so as an aid to you (and myself ;-)) I have added a few videos on YouTube showing in detail how you can setup InterForm400 to create PCL and PDF output in InterForm400 in cyrillic and Latin2 (Codepage 870/1153).
If you were in doubt: Cyrillic is used in russia (EBCDIC Codepage 880 and 1025), and 870/1153 is used in Bosnia/Herzegovina, Croatia, Czech republic, Hungary, Poland, Romania, Slovakia and Slovenia.
If you want to generate PCL or PDF in these codepages, then you should consider to watch these videos:
Create PCL in cyrillic: http://www.youtube.com/watch?v=5pXe52GNIQo&index=23&list=PLg0Wt8glOqM0uvgKXXCAzn3BecciCB4__
Create PDF in cyrillic: http://www.youtube.com/watch?v=m3VYSghKDCA&list=PLg0Wt8glOqM0uvgKXXCAzn3BecciCB4__&index=24
Create PCL in codepage 870/1153: http://www.youtube.com/watch?v=BF4VqFKdfQQ&index=25&list=PLg0Wt8glOqM0uvgKXXCAzn3BecciCB4__&t=220s
Create PDF in codepage 870/1153: http://www.youtube.com/watch?v=lL-9R4bx6ew&t=42s&list=PLg0Wt8glOqM0uvgKXXCAzn3BecciCB4__&index=26
Topics covered in previous episodes are:
- Duplex printing: Introduction
- InterForm400: Duplex setup
- InterForm400: Another use of the concat element
- InterForm400: More use of the concat element
- The STRWTRCHK option in InterForm400 and OS400 upgrades
- InterForm400: Use printer type HP4500 or HP4500D for color printing – not HP5C
- InterForm400: Correcting the time of outgoing emails
- Cookbook update: Save and restore spooled files without InterForm400
- Critical vulnerability found in the way Microsoft Windows handles printer drivers
- InterForm400: Replacement for IBM Advanced Function Printing Utilities
- InterForm400: Protecting the generated emails and PDF files
- InterForm400: Lookup in an XML file with the RTVPRPFE command
- InterForm400: PTFs to extend functionality of 2016 versions
- InterForm400: How to fix preview problems
- Interesting finding from the InterForm Development & Satisfaction Survey
- The Modules
1.Duplex Printing: Introduction.
Both InterForm400 and InterFormNG can print in duplex i.e. being able to print on both back and front of the paper – provided that you use duplex printer of course.
The alternative to duplex is called simplex printing – i.e. printing only on the front of each paper.
Duplex is normally used in these scenarios:
- Scenario 1: To save paper, or to reduce costs for stamps (because of the reduced weight): Here the input data is printed on both back and front of each physical paper.
- Scenario 2: To include additional, fixed data like ‘Terms and Conditions’ on the back of either the first or the last page of the print out. This extra page does not include any variable input data. This will be covered in a future Technical tip.
If you print input data on both back and front (scenario 1), then a special situation might occur:
If you imagine that you have multiple documents in a single input file, then you need to make sure that you are not mixing different documents on the same physical piece of paper. If you e.g. first print a single page invoice for customer A and then another invoice for customer B, then it would be a problem if the second invoice was printed on the back of the first invoice.
If you only are getting a single document inside each input file, then this is not an issue. But it might be good idea to build up the printing process to solve this challenge, if it should occur.
Both InterForm400 and InterFormNG includes standard functionality to solve this potential problem. In the next sections the solutions are described.
2.InterForm400: Duplex Setup.
Follow these simple instructions to setup duplex option (Scenario 1) and the solution to the challenge described above – for InterForm400:
In order to be able to print in duplex, you first need this:
- The file set you use in InterForm400 must have duplex enabled. You set that up via option 2. Work with file sets on the administration menu.
- The printer type you use for the merge in InterForm400 must be a duplex printer type. The duplex printer types in InterForm400 includes a ‘D’: HP4D, HP4D_PJL and HP4500D.
For this specific duplex type (scenario 1 referred to in the previous section) you need to consider this:
In order to print in duplex, you need to enable duplex on the overlay(s) used and set the correct duplex type:
The duplex type should be ‘Long binding’ or ‘Short binding’ and ‘Forced Front Page’ must be disabled. (You can use a duplex margin to make extra room for stapling or holes in the paper).
If you want to avoid mixing two documents on the same physical page, then you need to introduce two different overlays: One overlay (OVL1) to be selected for the first page of a new document, and another overlay (OVL2) for any other page. Therefore, you need something unique for the first page of a document, to select OVL1 in an overlay selector for the first page of a document. If we consider the InterForm400 demo spooled file (created via the service menu), then you can use the text in line 3 position 72 to 73 to verify, if this is the first page of a document:
(Remember to make sure, that the condition is not true for page number 11, 21..etc e.g. by including a space in the comparison like below – here we assume, that the number is left adjusted).
The condition for OVL2 should be a dummy condition that is always true. You can make OVL2 a complete copy of OVL1 if you insert a reference in OVL2 to OVL1 as an unconditioned overlay (S=Suboverlay).
The final thing is to activate ‘Forced front page’ for OVL1 and disable the same for OVL2:
Now you are ready and you can implement the merge, by referring to the overlay selector.
3. InterForm400: Another use of the concat element.
A customer had a special requirement the other day. They wanted to remap some spooled file text form the middle of the page, but that should be conditioned by text found in the top of the spooled file page. That is usually a bit of a challenge, but after considering a bit, I found that the concat element can (also) help you there:
The remap window (and conditioned overlays) normally use a condition, that must be found in the same spooled file line (or just above) the spooled file data, that you want to manipulate, but the concat element actually offers the possibility to condition the concat, on data found anywhere in the spooled file – independently of the data, that you want to remap:(Below we use the InterForm400 demo spooled file, that you can generate from the InterForm400 service menu)
The condition in this example is, that the text in position 8-23 in line 6 must be ‘Florence Flowers’. Only on the pages where this is found, the concat will be inserted.
The spooled file text that we ‘remap’ in the concat is name of the contact person, which is found further down on the spooled file. The condition is true on page 2 and 3:
We refer to the contact person via a concat detail line:
In this way the concat is ‘remapping’ Susan Sunflower’ on page 2 and ‘Wolly Weed’ on page 3.
4. InterForm400: More use of the concat element
To follow on from the above we wanted to included some inspiration of what you can use the concat element for, but it can actually do more than just combine data from different places in the input spooled file. Here are a couple of examples:
- It is possible to insert a condition on the ‘header’ of the concat. That condition can, similar the conditioned overlay, remap window and tabulators, be a combination of up to 4 conditions on the same spooled file line. The condition on the concat header can be used to decide, if the complete barcode should be included in the output or not.
- It is also possible to insert conditions on the detail level, when each spooled file text is retrieved from the spooled file. Here you can test for the text in the spooled file on the same spooled file line.
- When you insert a conditioned detail element in a concat, then you can also tell InterForm400, if an element is required or not. This means, that if the condition of a detail element is not met, then you decide if the complete concat should be ignored (required). That can e.g. be used with a barcode, so that the concat barcode will only be included if all the required fields are available.
- With the 2D barcodes you can define a special ASCII hex code prefix, which triggers InterForm400 to convert the next 2 characters into an ASCII character with this hex code. That can e.g. be used, if you want to insert unprintable characters like e.g. Hex 05 in the barcode to proceed some spooled file data in order to state what kind of data it is.
- When you use a concat in a conditioned overlay, you can even tell InterForm400, if the data for the concat should be found all over in the spooled file or in the spooled file lines, that are known in the conditioned overlay (relative spooled file lines).
- To sum up: The concat is so flexible, so that it is very likely, that you can build up your dynamic barcodes without the need to change your printing programs – and you do not need to call a InterForm400 user program to create a new, temporary spooled file either.
5. The STRWTRCHK option in InterForm400 and OS400 upgrades
There is a classic discussion around how you should implement automatic processing in InterForm400. There are mainly 2 ways to do that:
- An extra Outq pr. printer: By creating an additional output queue for each physical printer, so that Auto Forms Control monitors an input queue (without a printer attached) and place the merged spooled files on another output queue with a similar name. The input (output) queue might e.g. be named PRT01_IN and the output (output) queue might be named PRT01.
The naming standard is of course free, so some customers are even naming the input queue e.g. PRT01 and renaming the output queue connected to the printer to e.g. PRT01_OUT – in order not to have any change at all in the printing programs. - Share output queues between the printer and AFC: Some customers do not want to create any additional output queues, so they have chosen the special solution where Auto Forms Control (AFC) and the physical printer is sharing the same output queue.
In order for this to work you need to change the STRPRTWTR and the STRRMTWTR commands, so that the printer writer job only prints out spooled files with a specific form type. That is something, which you can activate in the InterForm400 configuration, where InterForm400 will change the STRRMTWTR and STRPRTWTR commands and add a call to the program APF3812/STRWTRCHK as the validity-checking program. This program will then ensure, that when you start a writer job, then the writer will only print out spooled files with a specific form type (as stated in the InterForm400 configuration) – if the same output queue is monitored by AFC.
My personal favorite is the first suggestion: To create an extra output queue. This is also how the majority of our customers are running.
If you are using option 2, then you could consider this:
- To copy the STRRMTWTR and STRPRTWTR commands to another library than QSYS, and place that library higher in the library list to avoid changing the original OS400 commands.
- In case of an OS400 upgrade the STRPRTWTR/STRRMTWTR commands may also be overwritten and suddenly you will print out only unmerged spooled files, as the writers will print out spooled files with any form type. To solve this you can go through the InterForm400 configuration to reactivate this feature.
- If you want to remove the InterForm400 and the APF3812 library, then you need first to disable the STRWTRCHK option in the InterForm400 configuration.
If you do not disable that, then the commands will still try to find the APF3812/STRWTRCHK programs; the commands will fail and no writerjobs can be started, before you remove the reference to this program.
6. InterForm400: Use printer type HP4500 or HP4500D for color printing – not HP5C
If you want to print in color in InterForm400, then you should always consider the HP4500 (or HP4500D) printer types over HP5C. One reason to stay away from HP5C is, that the PCL data stream is built for the 20+ year old HP Color Laserjet 5 printer. One important limitation of this is, that the printer is only able to print in 300 DPI, so you will get a problem, if you try to print 600 DPI images with this printer type.
In short: Use the printer type HP4500 (or HP4500D), if you want to print in color with InterForm400. Currently we keep the printer type to be backwards compatible.
7. InterForm400: Correcting the time of outgoing emails
InterForm400 is used widely to send out emails, but once in a while customers are complaining, that the time stamp of the outgoing emails are several hours wrong. This is in spite of the fact that the time is set correctly on the IBM i.
Of course it is not a problem in InterForm400, but it is related to the time zone setting of the IBM i. You can set the time and time zone via the WRKSYSVAL command, and relevant system values are: QTIME and QTIMZON.
** Warning **. You should not change any system value without the approval of the system administrator. A change of a system value may have some side effects, which you do not see right away, so think twice before you change these or any other system value. InterForm A/S cannot be held responsible for any problems or loss of data that are directly or indirectly caused by the suggestions below.
Normally the QTIME setting is set correctly, so when you compare the time of the IBM i with the local time, then the time is fine. The real problem is in the QTIMZON setting. You need to verify, if this is correct.
You should then consider changing the QTIMZON to the correct time zone, but take care: When you change QTIMZON, the value of QTIME will also change (automatically) to adapt to the new value, so you will probably need to correct QTIME immediately after changing QTIMZON.
In older OS400 versions (pre V5R3), you need to change the system value, QUTCOFFSET instead of QTIMZON.
Remember that changing the time can affect the logic of programs (time stamps might be affected) and even job schedulers, so you should consider to do the change when the machine is not busy.
8. Cookbook update: Save and restore spooled files without InterForm400
It has been possible to save and restore spooled files with the normal SAVOBJ command from V5R4, but many people are not aware of this. For our business partners, this feature is used e.g. to get a copy of spooled files from potential customers.
It simply works like a normal SAVOBJ for an output queue, where you need to specify SPLFDTA(*ALL) on the SAVOBJ command and
SPLFDTA(*NEW) on the RSTOBJ command. With this, any spooled file on the output queue will also be saved.
For some it is also a challenge to get the save file out to the IFS as a stream file e.g. for emailing, so I have also described how that can be done.
This is now included in a new update of the cookbook.
The updated cookbook can be downloaded here:
http://download.interform400.com/shares/public/CookBook.zip
9. Critical vulnerability found in the way Microsoft Windows handles printer drivers
Vectra Threat Labs have discovered a critical vulnerability (CVE-2016-3238) that is affecting all supported releases of Microsoft Windows.
The way end users connect to printers from Windows, allows attackers from within your local network - or even directly from the Internet, to place malicious driver files on your printer. This enables them to gain control to end-user devices connected to the printer, all across your internal network.
We recommend you read the whole article by Vectra Threat Labs here.
10. InterForm400: Replacement for IBM Advanced Function Printing Utilities
IBM i version 7.2 was the last release with IBM support for Advanced Function Printing Utilities (AFP) *.
AFP provides IBM i users with the basic functionalities of creating, designing and managing different resources, such as overlays for electronic forms and labels, etc.
InterForm400 is an enhanced alternative for AFP, capable of delivering the same standard functionalities - including a much wider selection of advanced Output Management features natively from the IBM i.
We have already helped several satisfied customers migrate to InterForm400.
*Source: IBM® Knowledge Center: IBM i 7.3 Release notes - June 29, 2016
11. InterForm400: How to protect the generated PDF files and emails
In general, the IBM i is not heavily haunted by viruses. However, the IFS is for the PCs like any other file server. If a PC e.g. runs a trojan horse, that encrypts and password protects any file it can reach (forcing you to pay a ransom for the password), then the files in the IFS can be hit like any other files.
One advice is to have a good and frequent backup. Another advice will be to make sure that the majority of the users only are able to read the contents in the IFS, but not modify it. You can e.g. use the CHGAUT command to change the authority of a folder (and change the authority of all subfolders and stream files inside).
When it comes to InterForm400, there is a dilemma: When an input spooled file is processed in Auto Forms Control (AFC), then the default way for InterForm400 to handle the spooled file is change the current user of the job, to the spooled file owner. The advantage with this is that any spooled file and other object created by the AFC job, will be owned by the same user profile as the original spooled file. This makes it easier for the users to track the outcome of their work, and for anyone else to see who created what. The dilemma now is, that if AFC should create a stream file in the IFS on the behalf of a normal user, then that user would need write authority, and this is exactly what we want to avoid...
The solution for PDF files
One solution is to tell InterForm400 to use another user profile, while creating the PDF files. You can do that in AFC, when you setup the call of the PDF file naming definition:
The default user is *SPLFOWNER, which of course refers to the spooled file owner. In this case we are using another special user profile with write authority instead, here called IFS_WRITER. You should never sign on as IFS_WRITER, and the user profile could be disabled, without a password, and with no special authorities – except write authority to the folder in question: (You can use the CHGAUT and WRKAUT commands to set and display the authorities).
The owner of the created PDF files will however be IFS_WRITER and not the original spooled file owner.
The solution for emails
The emails generated by InterForm400 are stored in the IFS inside /APF3812mail/Outbox (and /APF3812mail/Log if you set save=*YES, when you create the email).
Like for the PDF files, we have a problem when we need to create new emails (.eml files) in the outbox directory. The spooled file owner should only have read authority – not write authority. So first, we need a user profile with write authority, which we can use whenever we want to create or delete emails. In this example I have reused the IFS_WRITER user profile:
Now when we create the emails in AFC, we need to refer to a user profile with write authority to the outbox directory like so:
The email address of the sender (inside the email) is untouched, so that is not affected by the change of user profile. The normal users can still delete emails (with status *HELD or *READY) from the WRKMAILLOG command, as the email files in the IFS are not removed until the next time you run the APF3812/CLRMAILLOG command, which you should of course do on a regular basis.
12. InterForm400: Lookup in an XML file with the RTVPRPFE command
Whenever it makes sense, new functions in InterFormNG are also implemented in InterForm400 and vice versa. One example of this is the ability to lookup in a list with a key and get back a text stored for that key. That has been possible for many years in InterFormNG, and now with the 2016 versions you can do (about) the same in InterForm400.
The challenge:
You want to include/use information in a program, that can easily be maintained directly by end users. One way is to create a normal DB2 database, but then you need to create an extra program and a display file to enable users to edit the file. The actual lookup in the database might also be a bit of a task, if you want to do it from a CL program.
The InterForm400 alternative:
Instead of using a normal DB2 database, you can also provide an XML file, that your users can edit. The contents need to be like this XML file:
The structure of the xml file must be defined like above with the “properties” node and “entry” nodes as children. Each entry node has set the “key” attribute to the value, that you want to use for the lookup. The XML file can contain information about the encoding, but please note, that InterForm400 will not use that information, but instead look at the attribute of the stream file, so if the XML file is e.g. UTF-8 encoded, then you will need to make sure, that the CCSID of the XML file is correct. If e.g. the stream file is UTF-8 encoded, then you need to make sure, that the CCSID is set to 1208, which you can verify with WRKLNK and then use option 8 to display the attributes:
- or with the command: QSH CMD('attr /APF3812Home/Work/lookup.xml CCSID’).
You can change the CCSID with this command:
CHGATR OBJ('/APF3812Home/Work/lookup.xml') ATR(*CCSID) VALUE(1208)
When you want to look up into the XML file, then you can do that with the RTVPRPFE command e.g. from a split exit program like this:
The key value (which here is ‘DE_OC’) could also be retrieved from the spooled file via one of the entry variables, so that the language of the returned text fits the preferred language of the customer. (If in doubt: The example above will insert the text ‘Auftragsbestätigung’ in the new spooled file).
The text found in the XML file can of course also be some special offer of the week, that the sales department are dynamically updating – or it can be used as a part of an &&IMG command to dynamically include an image in the final output. (For more details about dynamic images you can refer to Appendix H in the InterForm400 manual).
13. InterForm400: PTFs to extend functionality of 2016 versions
InterForm400 functionality is usually the same for the official year versions, but sometimes we do add extra, new functionality (or solve issues) with a PTF. Recently we have added a few PTFs for InterForm400 that I think might be interesting for many customers.
Note: Instead of installing these PTFs, you can upgrade to the latest 2016 version (2016M05), in which these PTFs are included.
The PTFs must be installed in numeric order (starting with the lowest numbers). The interesting PTFs are:
PTF 5031: Remove leading spaces from variables in email finish definitions.
In previous versions any leading spaces in variables are also included in the email output, but with this PTF any leading spaces are trimmed.
Download link: http://download.interform400.com/shares/PTFs/APF5031.ZIP
PTF 5032: Support for large PDF files.
Until now the maximum size of a PDF file is 2Gb, but with this PTF the maximum size is increased from 2Gb to 10Gb. The extension was needed for a customer creating a 230.000 page long PDF file.
Download link: http://download.interform400.com/shares/PTFs/APF5032.ZIP
PTF 5034: In some, special situations the last concat in a conditioned overlay does not work in PDF. This is fixed with this PTF.
Download link: http://download.interform400.com/shares/PTFs/APF5034.ZIP
PTF 5036: Conditioned overlay/remap was not called in PCL after a concat.
In some situations a remap window/onditioned overlay is not called when using the new concat element – in PCL output. This problem is fixed with this PTF.
Download link: http://download.interform400.com/shares/PTFs/APF5036.ZIP
Procedure to install PTFs:
In order to install PTFs in InterForm400 you can use this procedure:
- Upload the zip file in the IFS inside /APF3812Home/PTFs.
- Load the PTF via these options in InterForm400:
12. Service functions
50. Apply PTF from the /APF3812Home/PTFs directory
Type in the PTF number e.g. 5031, press Enter and confirm installation with F10.
14. InterForm400: How to fix preview problems
It is possible to preview the merged result in a few places in InterForm400:
- In the green screen designer with F14
- From the APF3812/APFWRKOUTQ command with 5=Display for a merged spooled file
- From the graphical designer
In order to do the preview, InterForm400 will need to know the identification of the IBM i (as seen from the PC). An important prerequisite is that you have netserver access to the IFS, which can e.g. be done by mapping a network drive to a shared folder in the IFS. Another prerequisite is, that you use the same identification (either Netserver name or IP-address) for the IBM i in all of these places:
- In the InterForm400 configuration
- When you setup Netserver access e.g. via a mapped drive
- When you start up the graphical designer
You decide if you want to use the IP-address or the server name, but you need to use the same in all of the places for trouble-free previewing.
Additional help is included in the manual and the cookbook.
15. Interesting finding from our Development & Satisfaction Survey
One of the interesting facts the survey has shown, is the number customers considering changing ERP:
20 percent of all the participants are considering changing their ERP system.
Fortunately, no matter which new solution you are considering - InterForm can provide you an Output Management solution that you can use on any platform with any ERP system.
Read about our platform independent solution - InterFormNG
16. The Modules
Embedded PDF
Embedded any file format into PDF files
Digital Signature / PDF Security
PDF encryption, password protection and digital signatures
InterExcel400
Easy spool file conversion to Excel for IBM i
InterWord400
Simple and easy mail merge for IBM i (OfficeVision replacement)
XML generates synergy between you and your clients
WinPrint
Connect any printer to InterForm400
InterArchive400
Intelligent spool archiving for InterForm400
InterFax400 LIGHT
Distributes documents directly via fax (Batch)
InterFax400 PRO
Distributes documents directly via fax (Batch, Interactive & multiple fax lines)