I would like to add an event (or formula) to an array but I can't figure out how to do this. Here is the example array again:
event.value = (getField("Incent.4").value) + (getField("TimeBonus.4").value);
I would like to add an event (or formula) to an array but I can't figure out how to do this. Here is the example array again:
var personStats = {
"Jim Bean" : [45, "brown", 70, 175],
"Nancy Cardashian" : [36, "black", 68, 122],
"Bobby Gentry" : [72, "grey", 71, 165],
"Megan Foxx" : [28, "black", 67, 126]
}
I would like to add this event formula after the weight (4th entry) in every section:
event.value = (getField("Incent.4").value) + (getField("TimeBonus.4").value);
Where the "Incent.4" and the "TimeBonus.4" fields are actually determined by getting a result from another source by also referencing the name.
Here is the script I tried, can someone please correct this?:
var personStats = {
"Jim Bean" : [45, "brown", 70, 175, (event.value = (getField("Incent.4").value) + (getField("TimeBonus.4").value);)],
}
Bruce