Since LabVIEW is an ever-evolving Platform, it helps us (to help you) to provide a little more information about your situation. We always ask for code attachment (since, among other things, we can determine what version of LabVIEW you are using so we don't give you a LabVIEW 2016 "answer" if you are using LabVIEW 7.0), and even in a generic question such as yours, knowing the LabVIEW Version would enable us to suggest (or not) using a Conditional Array Indexing tunnel as part of the solution ... [that's a potential hint, by the way].
Bob Schor