Return to the CA Tips
Transfer data between an AS/400 and a PC.
If you're more comfortable with the PC side, you can use Client Access.br
Here's a sample PC batch file to do a generic transfer from the PC to an
AS/400.
It assumes you have previously downloaded the destination AS400 file
in order to create the .FDF file.
If you're transferring to files with
different names but the same fields, you can replace the "echo %3.FDF>>
%1.TFR" line with the specific .FDF file name instead of %3.
PUTFILE.BAT
===========
@echo off
rem Creates a request to transfer file %1 from the PC to library %2 file %3 member %4 on an AS/400 %5
rem %1 = PC file name rem %2 = AS/400 library rem %3 = AS/400 file rem %4 = AS/400 member rem %5 = AS/400 system name
rem Create xxx.TFR echo TRFRPC> %1.TFR echo.>> %1.TFR echo TO %2/%3(%4)>> %1.TFR echo %1>> %1.TFR echo 21>> %1.TFR echo %4.FDF>> %1.TFR echo 12 921>> %1.TFR echo.>> %1.TFR echo.>> %1.TFR echo.>> %1.TFR echo SYSTEM %5>> %1.TFR echo 0>> %1.TFR echo PROPS 00011>> %1.TFR echo.>> %1.TFR
rem Run %1.TFR rfrompcb /S %1.TFR
[report a broken link by clicking here]