Unknown Error when using User Role to set Field value
I have a form with a "Location" field that should be preset if the Role of the user filling in the form is "Storekeeper".
I therefore have the following 'Created or Edited' -> 'Load of the Form' workflow:
- if(thisapp.portal.isUserInProfile("Storekeeper"))
- {
- input.Location = "London";
- disable Location;
- }
However, whenever a user with the Storekeeper role tries to open the form, they get the following error:
Can anyone tell me what is causing the error?