Using variables to Set Field By Name

Discussion created by on Mar 27, 2018
Latest reply on Jul 8, 2018 by philmodjunk

I am having an issue trying to set the contents of a particular repetition in a particular field.


The solution has required me to make a generic data entry procedure. When the user wants to enter enter/change some data, they click on the relevant repetition of the "Item field" of the current layout and a script will start that stores the repetition number and the relevant field names to be stored as variables.  These are not used however until data is brought back from the Data Entry layout.  Variables are also created that store the values already entered into the current repetition of those fields.


Once in the Data Entry Layout, three data entry fields are populated with the data that was stored in the three variables that were brought across.  A screenshot of the script "Goto Entry Screen" attached shows how this is performed.


The user can change the values in those three fields.


When OK is pressed, the new values in those three fields are saved as variables and then moved back to the original layout.  A screenshot of the script "Goto Original Layout" is attached.


This is where it now breaks.  I cannot get the script to put those values back into the relevant fields and repetition on the original layout using the Set Field By Name steps.


On the screenshot "Variables with Value", I have shown (in red - marked Testing Debugging) that the correct data has been returned in the relevant variables.


I would really appreciate if someone could tell me why the Set Field By Name  steps are not populating the fields.