Progress
Language Reference


OUTPUT CLOSE Statement

Interfaces
OS
SpeedScript
All
All
Yes

Closes the default output destination or the output stream you name with the STREAM keyword in a prior OUTPUT TO statement.

SYNTAX

OUTPUT [ STREAM stream ] CLOSE 

STREAM stream

Specifies the name of a stream. If you do not name a stream, Progress uses the unnamed stream. See the DEFINE STREAM Statement reference entry in this book and the chapter on alternate I/O sources in the Progress Programming Handbook for more information on streams.

EXAMPLE

This procedure sends customer data to a file by using the OUTPUT TO statement. All statements that normally send output to the terminal send output to the file named cust.dat. After all customer data is written to the file, the OUTPUT CLOSE statement resets the output destination, usually the terminal. The final DISPLAY statement displays Finished on the terminal.

r-out.p
OUTPUT TO cust.dat.

FOR EACH customer:
    DISPLAY cust-num name address address2 city state country SKIP(2)
    WITH 1 COLUMN SIDE-LABELS.
END.

OUTPUT CLOSE.
DISPLAY "Finished". 

NOTES

SEE ALSO

DEFINE STREAM Statement, OUTPUT TO Statement


Copyright © 2004 Progress Software Corporation
www.progress.com
Voice: (781) 280-4000
Fax: (781) 280-4095