KB-1398 a!forEach does not save inputs in the order they are entered

Symptoms

When entering values into an editable grid, the input does not save in the box it was typed in, as seen below:

Cause

This issue is often seen when the value in the input field is indexed back into the original array. Unlike a!applyComponents, updated array items should be saved into fv!item instead of the local array variables. 

Action

Instead of saving into the original array as seen in the below code: 

a!textField(
value: local!list[fv!index].a,
saveInto: local!list[fv!index].a
)

Use the following syntax: 

a!textField(
value: fv!item.a,
saveInto: fv!item.a
)

Affected Versions

This article applies to Appian 17.2 and later. 

Last Reviewed: August 2017

Related
Recommended