COPYBYTES


9.2C

The COPYBYTES instruction retrieves the current number of bytes that have been used to transfer the source data file to the destination data file in an Enhanced Mode COPYFILE instruction. The instruction uses the following format:

 

 

[label]

COPYBYTES

{retbytes]

 

Where:

label

Optional. A Program Execution Label.

retbytes

Optional. A Numeric Variable that returns the number of bytes required to complete the transfer..

Flags Affected: ZERO,OVER

Note the following:

  1. The ZERO flag is set when the COPYBYTES instruction completes successfully.

  2. The OVER flag is set when the block count that is stored into the {retcount} variable is too large and causes an overflow that loses data.

  3. The {retbytes} value can be the same, less or more than the physical disk file size depending on the mode used for the COPYFILE. This value does include protocol management data required to complete a file transfer.

  4. The last COPYFILE byte count remains as the same value until the next COPYFILE is started. At that time, it is zero initially and a new byte count is set when the COPYFILE is finished.

 

 

See Also: System Interface Instructions

 



PL/B Language Reference CLOCK COPYCANCEL