|
#1
|
|||
|
|||
|
Hi all;
Just FYI, the only thing I know about scripting is what I learned in this document. In the example on page 34 of the "Scripting Reference", why do j & k represent the table index & value? Are these universal variables? I could find no other mention of this in the document. Regards; Jim Smiley |
|
#2
|
||||
|
||||
|
Those are the variables that were chosen for that example. The for loop that they use enumerates a table and the "j" and "k" variables were used just for that example. The syntax is
for index, value in table do operate on index and value end Code from scripting guide -- display a message for every table item for j,k in mytable do Dialog.Message("Table Item", j .. "=" .. k); end for the variable index they used "j" and for the variable at value, they used "k". They could have just as easily done this for index, value in mytable do Dialog.Message("Table Item", index .. "=" .. value); end HTH |
|
#3
|
|||
|
|||
|
Thanks Tigger;
Now I understand. I guess I just needed a little more explanation. Having completed the "Getting Started " Tutorial and the "Scripting Reference" I just wish to say that you guys have done a great job on AMS5. It will add functionality to my projects that I never dreamed I'd be able to provide. I've ordered my upgrade and can't wait for the 14th. Regards; Jim Smiley |
![]() |
«
Previous Thread
|
Next Thread
»
| Thread Tools | |
| Display Modes | |
|
|
All times are GMT -6. The time now is 04:31 AM.








Linear Mode
