ETU400 User Guide 011603
9-18
Entry and Exit Programs
With the PWRFROM3XB and PWRTO3XB commands, you can run any user-defined
programs before and/or after the file is transferred. Programs that run
before the file transfer occurs are called entry programs. Programs that
run after the file is transferred are called exit programs.
To use the entry and exit programs, enter the name of the program and the
library in which it resides in the ENTRYPGM and EXITPGM parameters.
NOTE:
Entry and exit programs do not have to be ETU programs.
Any program you can run on the AS/400 can be executed as an entry or exit
program. Remember that if you run a power command in batch mode, any
entry and exit programs must also be able to run in batch.
Example
Suppose you have a payroll file on the host that you want to transfer to
a PC. Before you transfer the file, you want to update it with current
payroll information by running a program that outputs to the payroll
file.
At the end of the file transfer operation, you want to run a program that
sends a message notifying the system operator that the file transfer is
complete.
Enter the file transfer and translation information as you would for any
file transfer, using the PWRFROM3XB command. In the ENTRYPGM parameter,
enter the name of the entry program to be run, along with the library in
which it resides. Do the same for the EXITPGM parameter.
When you execute the PWRFROM3XB command, the following events occur in
the order shown:
•
the entry program runs and updates the payroll file;
•
the file is transferred to the PC;
•
the exit program runs sending a message to the system operator.
Summary of Contents for ETU400
Page 1: ...i ETU400 User Guide AS 400FileTransferUtility...
Page 30: ...ETU400 User Guide 011603 2 5 old versions since most users do not modify these tables...
Page 183: ...ETU400 User Guide 011603 10 53...
Page 239: ...ETU400 User Guide 011603 E 1 Appendix E ERRORMESSAGES NATIVEMODE...
Page 264: ...ETU400 User Guide 011603 F 1 Appendix F ASCII EBCDICPRINTABLECHARACTERS...
Page 304: ...ETU400 User Guide 011603 H 1 Appendix H INTERNATIONALTRANSLATIONTABLES...
Page 309: ...ETU400 User Guide 011603 J 1 Appendix J ETUTHROUGHPUTCONSIDERATIONS...