Ray:

How do you figure 'expensive' and under what circumstances (ie processor and
number of users?)

It's been a while since a topic like this has come up for me. Actually, now
that I think of it, it was in the late 1970's when setting up local 9600
baud terminals and then being home with a 300 baud dial-up. At home, you
could actually see the cursor jumping to @(0) after every PRINT statement
that didn't have the trailing colon. It took being that slow (300) to see
what was going on.

So today, how do you measure expensive? And with todays flamethrowers, does
it really matter?

Respectfully,
Mark Johnson
----- Original Message -----
From: "Ray Wurlod" <[EMAIL PROTECTED]>
To: <[email protected]>
Sent: Tuesday, August 28, 2007 6:19 PM
Subject: Re: [U2] Clearing a portion of a screen


> Close, but the first column on the screen is #0.  Your approach clears to
the end of the line for each row processed.
>
> You can also use @(-3), which clears from current cursor position to end
of screen.
>
> Tip: the @() function is quite expensive to evaluate - evaluate it once
(outside the loop) rather than for every iteration.
> Similarly, the CRT statement is expensive to evaluate - minimize these
where possible.
> For example:
>
> CLEOL = @(-4)   ; * clear to end of line
> String = ""     ; * characters to clear portion of screen
> For row = FirstRow To LastRow
>    String := @(0,row) : CLEOL  ; * clear to end of row
> Next Row
> CRT String      ; * this statement actually effects the clearing
> -------
> u2-users mailing list
> [email protected]
> To unsubscribe please visit http://listserver.u2ug.org/
-------
u2-users mailing list
[email protected]
To unsubscribe please visit http://listserver.u2ug.org/

Reply via email to