Progress
Language Reference
UP Statement
Positions the cursor on a new line in a down or multi-line frame.
When the block specifying the down frame iterates, Progress automatically advances one frame line. Use the UP statement if you want to move to a different display line at any time.
For more information on down frames, see the DOWN option of the Frame Phrase.
SYNTAX
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.
expression
Represents the number of occurrences of data in the frame that you want to move up. UP is the same as UP 1, except that nothing happens until the next data handling statement affects the screen. Several UP statements in a row with no intervening displays are treated like a single UP 1. UP 0 does nothing. If expression is negative, the result is the same as a DOWN expression.
frame-phrase
Specifies the overall layout and processing properties of a frame. For more information on frame-phrase, see the Frame Phrase reference entry.
EXAMPLEThis procedure starts at the bottom of the screen and displays all the customer database records. The default frame for the FOR EACH block is a down frame. The DISPLAY statement uses that frame. Therefore, Progress automatically advances down the screen one line after each iteration. You must use an UP 2 rather than an UP 1 because there is an automatic DOWN 1 performed on the display frame at the end of each iteration of the FOR EACH block.
NOTES
- When a frame is a down frame, Progress automatically advances to the next frame line on each iteration of the block that it is scoped to, whether or not you use the DOWN statement. If you do not want Progress to do this automatic advancing, name the frame outside of the current block. For more information on frames, see the Progress Programming Handbook .
- When Progress reaches the top frame line and then encounters an UP statement, it clears the frame and starts at the bottom line of the frame. However, if you use SCROLL, Progress moves everything in the frame down one row.
SEE ALSO
DEFINE STREAM Statement, DOWN Statement, Frame Phrase, SCROLL Statement
Copyright © 2004 Progress Software Corporation www.progress.com Voice: (781) 280-4000 Fax: (781) 280-4095 |