The SNDDOMFAX command allows you to fax OS/400 spooled files of type AFP or SCS directly from an OS/400 command line using Domino Fax for iSeries. This is sample code only.
July 26, 2002: This updated version of SNDDOMFAX supports multiple mail boxes.
(C) Copyright IBM Corp. 2000
All rights reserved.
US Government Users Restricted Rights -
Use, duplication, or disclosure restricted
by GSA ADP Schedule Contract with IBM Corp.
Licensed Materials - Property of IBM
Command requirements and restrictions
Transferring Files to your iSeries System
Creating the SNDDOMFAX
Command (only necessary if you change the command)
After downloading the sndfax.zip file and unzipping it, you have the following files on your workstation:
readme.html - the file you are currently readingThe save file (qfxdsav) listed above must be transferred from your workstation to an iSeries system in binary mode as directed below.
qfxdsav.bin - OS/400 save file of library QFXDTOOLS. This library contains all SNDDOMFAX objects and source.
a. Create an OS/400 library and save file in preparation for transferring qfxdsav to the iSeries.
For example:
cd xxxx [change to the directory on your workstation that contains the save file]ftp [your iSeries system name or IP address]
Name: [Enter your iSeries user profile name and press enter]
Password: [Enter your iSeries password and press enter]ftp>binary
Representation type is binary IMAGE.
ftp>put qfxdsav mylib/qfxdsav (replace
ftp>quit
The qfxdsav save file for the QFXDTOOLS library is now on your iSeries system.c. Restore the QFXDTOOLS library from the qfxdsav save file.
On the iSeries system where you transferred QFXDSAV, run the following command:
RSTLIB SAVLIB(QFXDTOOLS) DEV(*SAVF) SAVF(MYLIB/QFXDSAV)When the RSTLIB command completes, you have a new library on your iSeries system called QFXDTOOLS which contains all of the SNDDOMFAX objects and source as listed below:
|
|
|
SNDDOMFAX | *CMD | compiled command, source in QCMDSRC |
SNDDOMFAX | *PGM | compiled command processing program |
QFAXCALHPT | *MODULE | Module needed to create SNDDOMFAX program, source in QCSRC |
QFAXSETENV | *MODULE | Module needed to create SNDDOMFAX program, source in QCSRC |
QFAXSNDFAX | *MODULE | Module needed to create SNDDOMFAX program, source in QCSRC |
QFXDFINE | *WSCST | Workstation customization object needed for call to Host Print Transform, source in QTXTSRC |
SDFMSG | *MSGF | contains the command message file |
QCSRC | *FILE | source for the command processing program |
QCMDSRC | *FILE | source for the SNDDOMFAX command |
QTXTSRC | *FILE | source for the workstation customization object |
Review the user considerations before attempting to run the command.
Use the WRKSPLF command to identify the attributes of the spooled file you wish to fax.
Enter SNDDOMFAX on any OS/400 command line and press F4 to display the command prompt.
Enter the required information:
- Domino Server Name (for example, as26faxdom)
Note: This can be any Domino server located on the iSeries system that has access to the fax server via foreign domains.- Fax recipients (for example, Susan Green@9-555-1234@fax)
- From information (name and information about sender of fax)
Note: You can specify the most recently spooled file of a particular name (for example, QSYSPRT) for your current session by using * as the Job Name.
You only need to perform the steps described in this section if you make changes to the command. You do not need to create the command if you plan to use it without customizing it.
Note: To successfully run the these commands, you must have the following items installed on your iSeries system (use DSPSFWRSC command to determine if they are already installed):
ADDLIBLE QNOTESAPI
CRTCMOD MODULE(QFXDTOOLS/QFAXCALHPT) SRCFILE(QFXDTOOLS/QCSRC) TEXT('SNDDOMFAX
module - calls Host Print Transform')
CRTCMOD MODULE(QFXDTOOLS/QFAXSETENV) SRCFILE(QFXDTOOLS/QCSRC) TEXT('SNDDOMFAX
module - sets up Notes environment') CRTCMOD MODULE(QFXDTOOLS/QFAXSNDFAX)
SRCFILE(QFXDTOOLS/QCSRC) TEXT('SNDDOMFAX module - sends the fax')
/* create the SNDDOMFAX command processing program */
CRTPGM PGM(QFXDTOOLS/SNDDOMFAX) MODULE(QFXDTOOLS/QFAXCALHPT QFXDTOOLS/QFAXSETENV QFXDTOOLS/QFAXSNDFAX) BNDSRVPGM(QNOTES/LIBNOTES QNOTES/QNNINAPI QSYS/QWPZHPT1) USRPRF(*OWNER) AUT(*USE)
/* change the owner of the SNDDOMFAX program to QSYS */
CHGOBJOWN OBJ(QFXDTOOLS/SNDDOMFAX) OBJTYPE(*PGM) NEWOWN(QSYS)
/* create the command */
CRTCMD CMD(QFXDTOOLS/SNDDOMFAX) PGM(QFXDTOOLS/SNDDOMFAX) SRCFILE(QFXDTOOLS/QCMDSRC) TEXT('SNDDOMFAX command') MSGF(QFXDTOOLS/SDFMSG) PRDLIB(QFXDTOOLS) AUT(*EXCLUDE)
Note: Use the Work with Authority command (WRKAUT) to authorize appropriate individuals or groups to run the SNDDOMFAX command.
/* Create the workstation customization object */
CRTWSCST WSCST(QFXDTOOLS/QFXDFINE) TEXT('SNDDOMFAX workstation
customization object') SRCFILE(QFXDTOOLS/QTXTSRC)