* VFP6 lparameters toObject for ix = 1 to alen(myArray) if type("myArray[ix]") = "O" and myArray[ix]=toObject return ix endif endfor return 0 * VFP5-3 lparameters toObject for ix = 1 to alen(myArray) if type("myArray[ix]") = "O" and compobj(myArray[ix],toObject) lcOrgName = myArray[ix].name && Save name myArray[ix].name = "__TEMP__" && Cahnge temporarily llSameObject = compobj(myArray[ix],toObject) && toObject.name changed too ? myArray[ix].name = lcOrgName && Restore name if llSameObject return ix endif endif endfor return 0Beware this routine threat the array as a simple one dimensional.