Page 1 of 1 1
Topic Options
#152866 - 2005-12-05 07:19 PM Use macro over and over or assign to variable?
sixdoubleo Offline
Starting to like KiXtart

Registered: 2004-02-06
Posts: 118
Loc: California, US
Is there a performance benefit to assinging a macro to a variable and then using the variable. Or is it just as fats to use the macro throughout the code?

I was always adiment about:

$ws = @WKSTA
and then using $ws from there on.

Lately I have been using @WKSTA more throughout the code.

Which is better?

Top
#152867 - 2005-12-05 07:37 PM Re: Use macro over and over or assign to variable?
Howard Bullock Offline
KiX Supporter
*****

Registered: 2000-09-15
Posts: 5809
Loc: Harrisburg, PA USA
This has been discussed a few times over the years. I think that last concensus was that KiXtart does a much better job of caching the data and therefore it is no longer suggested to store all macro values in variables.

I am sure I will be corrected if I have mis-spoken.


Edited by Howard Bullock (2005-12-05 07:59 PM)
_________________________
Home page: http://www.kixhelp.com/hb/

Top
#152868 - 2005-12-05 07:56 PM Re: Use macro over and over or assign to variable?
sixdoubleo Offline
Starting to like KiXtart

Registered: 2004-02-06
Posts: 118
Loc: California, US
Thanks. That was my suspicion as well.
Top
#152869 - 2005-12-05 08:06 PM Re: Use macro over and over or assign to variable?
Les Offline
KiX Master
*****

Registered: 2001-06-11
Posts: 12734
Loc: fortfrances.on.ca
There are however, a couple of macros that would make a return trip for updates.
_________________________
Give a man a fish and he will be back for more. Slap him with a fish and he will go away forever.

Top
#152870 - 2005-12-06 02:16 AM Re: Use macro over and over or assign to variable?
sixdoubleo Offline
Starting to like KiXtart

Registered: 2004-02-06
Posts: 118
Loc: California, US
Quote:

There are however, a couple of macros that would make a return trip for updates.




@DATE and @TIME ??

Top
#152871 - 2005-12-06 02:38 AM Re: Use macro over and over or assign to variable?
Les Offline
KiX Master
*****

Registered: 2001-06-11
Posts: 12734
Loc: fortfrances.on.ca
OK, more than a couple.
_________________________
Give a man a fish and he will be back for more. Slap him with a fish and he will go away forever.

Top
Page 1 of 1 1


Moderator:  Arend_, Allen, Jochen, Radimus, Glenn Barnas, ShaneEP, Ruud van Velsen, Mart 
Hop to:
Shout Box

Who's Online
0 registered and 764 anonymous users online.
Newest Members
ManuvdWielNL, Sir_Barrington, batdk82, StuTheCoder, M_Moore
17887 Registered Users

Generated in 0.161 seconds in which 0.096 seconds were spent on a total of 12 queries. Zlib compression enabled.

Search the board with:
superb Board Search
or try with google:
Google
Web kixtart.org