I'm trying to make a program that requires exactly 19 rows (on screen, not the code itself) to calculate and output on screen the names, values, and units of 5 different variables. e.g.

"A="
A
[Kilograms]

"B="
B
[Liters]

"C="
C
[meters]


But output() is limited to only 8 rows, so I can't do it with it alone. Is there any way I can bypass this limitation in order to have different screens or be able to scroll down to see the other variables?
There are plenty of options. If there's space on screen, you might consider having two columns, using Output( to print to different columns.

If you want to do scrolling, the easiest option is the Pause command (PRGM > 8). Just Pause after outputting one screenfull, and then Pause again after the second. Unfortunately, Output doesn't support letting you scroll; you have to ClrHome and then draw a new screenfull of text.

If you're more adventurous, you can do something like
Code:
:Lbl S1
:Output(stuff)
:0->K
:While K=0
:getKey->K
:End
:If K=26
:Goto S2
:Goto S1
:
:Lbl S2
:Output(morestuff)
:0->K
:While K=0
:getKey->K
:End
:If K=24
:Goto S2
:If K=26
:Goto S3
:Goto S2
:
:Lbl S3
:Output(evenmorestuff)
:etCetera(etc.)
Basically, you have a label for every screen, and then code that lets the user jump to different screens using the arrow keys, or whatever.

Another option is using the graph screen for output, using the Text( command, but that's another post.
There is no other way in TI-BASIC to display more text to the screen than the output() command allows you to.
What I would recommend doing is creating a section of your program that allows the user to scroll the displayed list. Or, you could instead have the first 8 rows shown, then a pause command that waits for the user to press enter, and then display the next 8 rows, another pause, and finally display the last 3 rows.
KryptonicDragon wrote:
There is no other way in TI-BASIC to display more text to the screen than the output() command allows you to.
I believe that by using the graphscreen's Text( command, one can achieve somewhere around 16 lines onscreen at once. You won't be able to use this and homescreen output commands simultaneously, however. The graph screens also allows for a much larger range of outputs, from lines across the screen, to circles, to even entire works of art.

Example of the Text( routine:

Code:
Text(ROW,COLUMN,VALUE/STRING
"Outputs the value or string at (ROW,COLUMN) on the graphscreen in a four pixel tall font, much smaller than the Output( text.

Text(1,1,"Hello, this is the syntax for Text(!
If you put the calc into horizontal mode, you can technically use homescreen text and graphscreen text at once, this might help a little with managing text. NOTE: the max rows is reduced by this method, I don't know how much, though.
You could do it like a html <marquee> tag. It would require a long string of text, and a sub command. There’s a good code snippet for this, it can be altered to make it more output( friendly.

Oh god. Not those...
CalcMeister wrote:
You won't be able to use this and homescreen output commands simultaneously, however.
You can put large text on the graph screen with Text(-1,X,Y,"text").
  
Register to Join the Conversation
Have your own thoughts to add to this or any other topic? Want to ask a question, offer a suggestion, share your own programs and projects, upload a file to the file archives, get help with calculator and computer programming, or simply chat with like-minded coders and tech and calculator enthusiasts via the site-wide AJAX SAX widget? Registration for a free Cemetech account only takes a minute.

» Go to Registration page
Page 1 of 1
» All times are UTC - 5 Hours
 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

 

Advertisement