Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Scrolling in Assembly

Status
Not open for further replies.

NANOSAURUS

Programmer
Mar 12, 2001
1
0
0
US
Hi, I was wondering....How do I scroll in assembly. Also where in the buffer does the scrolled up/dn part of the page go.
Thanks in advance....NANOSAURUS
 
You can scroll a DOS text screen by calling int10h with AH = 06h to scroll the page up, or AH = 07h to scroll the page down. The value in AL is the number of lines to scroll.
BH = character for 'blank lines'
CH & CL = row and column of upper left corner
DH & CL = row and column of lower right corner

See Ralph Browns interupt list for more stuff....



Kim_Christensen@telus.net
 
BH=ATTRIBUTE for blank lines, not character.

The scrolled out portion is thrown away.

NOTES:
To clear out the window, set al=0. You may set it so that al>number of rows, but some BIOS implementations don't handle that properly. al=0 is slow on some implementations, but some check for that condition and immediately clear out the window. al=0 is the most portable if you want to clear a portion of the screen.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top