Find - RefCollectionAlias
Member of: RefCollectionAlias Script
Searches for the specified form in the form list, returning its index (or a negative number if the form isn't found in the list)
SyntaxEdit
int Function Find(ObjectReference akFindRef) native
ParametersEdit
- akFindRef: Reference to search for
Return ValueEdit
The index of the reference in the reference collection. If the reference isn't found, this number will be negative.
ExamplesEdit
; Find the bob in the collection
int index = People.Find(Bob)
If (index < 0)
Debug.Trace("Bob could not be found.")
Else
Debug.Trace("Found Bob at index " + index + " in the people collection.")
EndIf