I’m having trouble figuring out how to assign more than 1 variable in the OnEvent. In the code below, the Wrong[0] is ONLY assigning number 0 in the handler, being Wrong1. I need to figure out how to put all 3 variables there, instead of just one. Thanks!
You are literally adding the onEvent only on the first element of the list, if you want you can simply loop over the list and add the event on each one.
I am not really sure about the language or technology you are using, but onEvent looks like a callback of sort.
You can loop over your items and add your events, each language has a way to iterate over a collection and “do something”.
For example a “for” loop in JavaScript looks like:
for(let i = 0; i < Wrong.length; i++) {
onEvent(Wrong[i] ...)
}
Meaning that on each iteration i will change accessing a different value of your array.