Integration between BlueFax and InterForm/400

How can I integrate BlueFax with InterForm/400?

If you want InterForm, to automatically send a spool file to BlueFax, these rules must be followed:

  1. One (1) Spool File = One (1) recipient. It applies, that if you have a Spool File with different recipients on different pages - the Spool MUST be split up in one Spool pr. recipient.
  2. BlueFax must know the recipient. There are different methods to identify the recipient; a) via the SNDFAXSPLF command, b) .FAXNO(12345678) in the Spool File Data and c) via a fixed recipient to a output file.

This document will describe how to use SNDFAXSPLF.

The enclosed program (SNDIFFAX) can send a fax via BlueFax. It requires, that minimum the recipients fax number, and name, is found in "User Defined Data" on the Spool file.

You must use the OS/400 command OVRPRTF:

OVRPRTF FILE(MYSPOOL) USRDFNDTA('FAX:004645768191 Agent Data ApS')

You must then tell InterForm/400 (Auto Forms Control), that the "User Exit Program" must be used in a specific Output queue.

It requires that you have authorization to make changes in those of your application programs, where OVRPRTF is to be placed before data are written in the Spool file. (Remember 1 Spool File = 1 recipient).

You might have to make a fix in your application programs, so there is a CLOSE after every Spool File Fax.

This method is very similar to the normal way a Spool file is handled in BlueFax. (See Programmers Reference Manual for SNDFAXSPLF)

Split User Exit Program

You can find yourself in a situation, where you are unable to make fixes, in you application programs (e.g. no source available). But there is still help to find in InterForm/400.

InterForm/400 has a facility enabling you, to split one spool file in many small Spool files. There are different ways to do this - please advice your InterForm manual.

It is e.g. possible to call a "User Exit Program" in the beginning of each split. This "User Exit Program" can receive data from the Spool file, which can be used to turn up entries from a 3rd party database.

The User Exit Program SPLEXIT is made for this purpose. The program is prepared so it is possible for the user to make is own program to 1) select user data form the database, 2) return the fax number and recipients name. This will enable the "User Defined Data" on the new Spool file to contain information of the recipient. You can now use the User Exit Program of "InterForm/400 Auto Forms Control’s" as described previously.

The User Exit Program SPLEXIT is only used to CALL another program (STMT 70.00) which can be used to fetch e.g. a fax number and a recipient.

SPLEXIT' s 5 first parameters are data, which comes directly from the Spool file, which is fetched by InterForm/400's split function. Example: The first field could contain a customer number which is fetched from the Spool file and send on the User Exit program (SPLEXIT).

integra1.gif (11118 bytes)

The User Exit program can call your own user program with the necessary parameters. This program could e.g. be a RPG program which does nothing but a simple CHAIN to your customer database with the customer number (ENTRYTXT1). Example:

integra2.gif (6130 bytes)

The field &RETURNUDFD (in User Exit program SPLEXIT STMT 76.00) changes the User Define Data for the Spool File which is used by Auto Forms Control’s user exit program (as described above).

(The examples are the courtesy of System og Metode ApS).

Download File

How to install file:

  • Move the file to the APF3812 folder
  • Go Bluefax
  • RSTLIBFLR FAXTOOLS
  • Use the program SPLEXIT in InterForm's Split Definition
  • Use the program SNDIFFAX in InterForm's AutoFormsControl as a Call Program