FindIndex question

Neville Smythe neville.smythe at optusnet.com.au
Sun Mar 24 05:45:05 EDT 2024


I am using FindIndex on a dataGrid

     dispatch "FindIndex" to tDataGrid with pKey, pSearchingString

and I can pass multiple pKey, pSearchingString pairs such as “col1",pSearchStr1,”col2”,pSearchStr2 as cited in the dictionary entry

But there is also a rather cryptic note at the end of the FindIndex dictionary entry

     Note that pKey can also be an array if you want to use array-valued array indexing to locate pSearchingString.

I took that to mean one could set up an array pKey with values such as  pKey[“col1”]=pSearchStr1,  pKey[“col2”]=pSearchStr2
and then just pass the pKey array. But that doesn’t work. 

Neither does using two indexed arrays pKey and pSearchStr with  pKey[1]=“col1”, pSearchStr[1]=pSearchStr1,pKey[2]=“col2”, pSearchStr[2]=pSearchStr2
 
Anyone know what it does mean?


Neville Smythe






More information about the use-livecode mailing list