Indexof

Forms Developer Guides Scripting Data Array

indexOf(submission)

array.indexOf(submission);
array.indexOf(submission_data)
array.indexOf(permalink);

Returns the index of a submission within the SubmissionDataArray. It accepts SubmissionData, Submission, and permalink strings. If the submission is not found, it will return -1.

To get a boolean indicating whether the submission exists within the array, use the contains method.