'THREADED variables in FOR NEXT?
'
'Should THREADED variables be used primarily for
'passing values between functions and use REGISTER
'variables for performance. Does the same thing
'apply to GLOBAL integers and longs. Use REGISTER
'variables for performance and then assign the result
'to a THREADED or GLOBAL variable only when needed?
------------------
[This message has been edited by Mike Doty (edited September 03, 2006).]
Code:
#DIM ALL #DIM ALL #COMPILE EXE THREADED t AS LONG ' FUNCTION PBMAIN AS LONG t = 0 'valid DO UNTIL t = 1 'valid INCR t 'valid MSGBOX STR$(t) LOOP ' FOR t = 1 TO 1 'invalid numeric scalar variable expected NEXT END FUNCTION
'Should THREADED variables be used primarily for
'passing values between functions and use REGISTER
'variables for performance. Does the same thing
'apply to GLOBAL integers and longs. Use REGISTER
'variables for performance and then assign the result
'to a THREADED or GLOBAL variable only when needed?
------------------
[This message has been edited by Mike Doty (edited September 03, 2006).]
Comment