VIEW PRINT to freeze part of the screen.by Solitaire (Login Solitaire1)
To freeze the screen and allow scrolling only in the rows between x and y:
VIEW PRINT x TO y
To unfreeze, use VIEW PRINT alone. Here is an example program:
CLS 'Set scroll area with VIEW PRINT; freeze top and bottom lines
PRINT "The top line will stay frozen. To unfreeze, press the Tab key."
LOCATE 24: PRINT "The bottom line will stay frozen";
VIEW PRINT 3 TO 23
PRINT "The center of the screen will scroll text entries."
PRINT "The top and bottom lines will be frozen and won't scroll."
PRINT "Keep pressing any key to speed up the scrolling."
count = 0
count = count + 1
PRINT "This is repeat # "; count
K$ = INKEY$
LOOP UNTIL K$ = CHR$(9)
VIEW PRINT 'This will unfreeze the screen
PRINT "Press Esc when you are ready to end program."
K$ = INKEY$
LOOP UNTIL K$ = CHR$(27)
|Response Title||Author and Date|
|* I take it you use SLEEP 1 to reduce CPU usage.||on Dec 13|
|No, it's just to slow things down so you can see each line.||Solitaire on Dec 14|
|Apparently in QB 4.5, SLEEP doesn't decrease CPU usage.||on Dec 14|
|NOT IN THE VISBASICS||OPRESION on Dec 14|
|* WHY DON"T YOU EVER USE LOWER CASE EL STUPIDO!||CLIPPY on Dec 14|
|MY PLEASURE (URL)*||OPRESION on Dec 14|
|* You are NOT fooling me! You copied and pasted that Link! :-P||Clippy on Dec 14|
|Interesting about UC...||on Dec 14|
|Please don't refer to other people who try to help as stupid, because relatively speaking||on Dec 14|