Multiple Screen Displays

by Solitaire (no login)

The normal screen length is 24 without scrolling. If you want to display more than 24 lines, I would add a pause for the user to read what's on the screen before continuing.

Here is a simple example:

DIM x AS INTEGER
CLS
FOR x = 1 TO 23
PRINT "This is line # "; x
NEXT x
PRINT "Press any key to continue..."; INPUT$(1)
FOR x = 24 TO 46
PRINT "This is line # "; x
NEXT x
END

==============================================================
The following example is more elaborate:

DIM snum AS STRING, num AS INTEGER, x AS INTEGER, lin AS INTEGER, dis AS INTEGER
lin = 0
CLS
INPUT "How many screens to display:  ", snum$
num = VAL(snum$)
If num = 0 THEN num = 1
FOR display = 1 TO num
    dis = 0
    DO
        dis = dis + 1
        lin = lin + 1
        PRINT "This is line # "; lin
    LOOP UNTIL dis = 23
    IF display [ num THEN
        PRINT "Press any key to continue..."; INPUT$(1)
    END IF
NEXT display
END


Note: The less than symbol does not display on this forum. Please substitute the less-than symbol for the [ on this line:

IF display [ num THEN

Posted on Dec 3, 2011, 9:13 AM

Respond to this message   

Return to Index


Response TitleAuthor and Date
Re: Multiple Screen Displays on Dec 4
 Thank you, Michael. Revised Multiple Screen Displays with more options:Solitaire on Dec 6