I have this code:

Code:
"Press any button to continue."→Str1
length(Str1→N
1
Repeat getKey
If dim(rand(15
Text(57,1,sub(Str1+"                             ",1+NAns,N
not(Ans
End

The only problem with this is that it doesn't let my full text blink:

Your problem is, is that spaces do not have the same width as normal characters. So, for example, the character P is equal to 3 or 4 spaces. In that way, you should have 94 spaces, one for each pixel.

EDIT:
Code:
If dim(rand(15
seems to be always true Smile rand(15 generates a list of 15 random float numbers from 0 to 1. So the dimension is always 15 -> that if-statement is always true
PT_ wrote:
Your problem is, is that spaces do not have the same width as normal characters. So, for example, the character P is equal to 3 or 4 spaces. In that way, you should have 94 spaces, one for each pixel.

EDIT:
Code:
If dim(rand(15
seems to be always true Smile rand(15 generates a list of 15 random float numbers from 0 to 1. So the dimension is always 15 -> that if-statement is always true


I tried 94 space, but that didn't work and shows exactly the same thing.
What would you suggest me to do with that if statement?[/img]
You should change your code as well as follows, otherwise you only draw N spaces instead of the 94.

Code:
Text(57,1,sub(Str1+"                                                                             ",1+94Ans,Nnot(Ans)+94Ans


You don't need that if-statement, only rand(15 is good enough for a time delay.
Welcome to Cemetech, RuuddeRuijter! You should take a moment to post in our Introduce Yourself thread if you get a chance. PT_'s solution is a good one; another option would be to use lines to erase the text:
Code:
For(X,Ymin,Ymin+6ΔY,ΔY
Line(Xmin,X,Xmax,X,0
End
PT_ wrote:
You should change your code as well as follows, otherwise you only draw N spaces instead of the 94.

Code:
Text(57,1,sub(Str1+"                                                                             ",1+94Ans,Nnot(Ans)+94Ans


You don't need that if-statement, only rand(15 is good enough for a time delay.

Okay, I will try that as soon as I get home, thank you very much.

KermMartian wrote:
Welcome to Cemetech, RuuddeRuijter! You should take a moment to post in our Introduce Yourself thread if you get a chance. PT_'s solution is a good one; another option would be to use lines to erase the text:
Code:
For(X,Ymin,Ymin+6ΔY,ΔY
Line(Xmin,X,Xmax,X,0
End


Thank you, I will post something in the introduce yourself section. I didn't think of drawing a line, thank you. Btw how can you type a Δ in the TI-84 plus calculator?
That delta is not a separate token on the calculators. You can find DeltaY in [VARS] - [WINDOW] - [DELTAX] or [DELTAY]
PT_ wrote:
That delta is not a separate token on the calculators. You can find DeltaY in [VARS] - [WINDOW] - [DELTAX] or [DELTAY]


Oh okay. Thank you for clearing that up.
update:
PT_ wrote:
You should change your code as well as follows, otherwise you only draw N spaces instead of the 94.

Code:
Text(57,1,sub(Str1+"                                                                             ",1+94Ans,Nnot(Ans)+94Ans


You don't need that if-statement, only rand(15 is good enough for a time delay.

When I try this:

Code:
"Press any button to continue."→Str1
length(Str1→N
1
Repeat getKey
rand(15
Text(57,1,sub(Str1+"                                                                             ",1+94Ans,Nnot(Ans)+94Ans

I get this error ERR:DOMAIN next to (Ans)+94Ans
I'll now try the other solution.
Update2:
KermMartian wrote:
Welcome to Cemetech, RuuddeRuijter! You should take a moment to post in our Introduce Yourself thread if you get a chance. PT_'s solution is a good one; another option would be to use lines to erase the text:
Code:
For(X,Ymin,Ymin+6ΔY,ΔY
Line(Xmin,X,Xmax,X,0
End

I tried this and got an ERR:SYNTAX on that last delta Y thing
Bump
Oops sorry, my mistake. It should be

Code:
Text(57,1,sub(Str1+"                                                                             ",1+NAns,Nnot(Ans)+94Ans


For that Syntax-error, are you sure you have typed the TOKEN DeltaY? Does it have an extra space after it?
PT_ wrote:
Oops sorry, my mistake. It should be

Code:
Text(57,1,sub(Str1+"                                                                             ",1+NAns,Nnot(Ans)+94Ans


For that Syntax-error, are you sure you have typed the TOKEN DeltaY? Does it have an extra space after it?

Sorry for this very late answer, but I still don't have it working. How do I get that N before ans and not?I now got ERR:DOMAIN and my cursor stops at 94Ans
  
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