|
mecca Newbie
Joined: 05 Oct 2005 Posts: 8
|
Posted: Sun Oct 09, 2005 10:59 am
about the index of array |
#var ary %array("a","b","c")
Is there a function that I can get the index of a element in ary ?
for example:
#sh %function("a",ary) -> it will show: 0 |
|
|
|
MattLofton GURU
Joined: 23 Dec 2000 Posts: 4834 Location: USA
|
Posted: Sun Oct 09, 2005 4:29 pm |
Nope. Not strictly for arrays. Since they look just like stringlists, you could try the various stringlist functions but I've no idea if they will work on arrays.
|
|
_________________ EDIT: I didn't like my old signature |
|
|
|
Vijilante SubAdmin
Joined: 18 Nov 2001 Posts: 5182
|
Posted: Mon Oct 10, 2005 1:42 am |
I would suggest abandoning arrays entirely very early in any sort of script creation. The purpose of arrays in zMud is to provide proper connectivity to COM objects expecting an array format. The array system in zMud simpy is not as robust as string lists. This is because arrays are provided nearly entirely through COM objects. Learn to use string lists, they provide all the functionality of an array and then much more, and give you the option of still working with them as a regular string. Definitely well worth the extra learning.
|
|
_________________ The only good questions are the ones we have never answered before.
Search the Forums |
|
|
|
|
|