Hi
In Ui there was user picker field if i choose more than one (max selection is 3 ) and submit request after that in read only the selected users we are showing in summary dashboard there user want first name and last name to be displayed instead user name
Below is the logic i am using to display selected user details in text field
a!textField( label: "Requested On Behalf:", labelPosition: "ADJACENT", value: a!forEach( items: a!defaultValue(ri!MDSRequest.requestedonBehalf, {}), expression: if( a!isNullOrEmpty(fv!item), {}, if( a!isNullOrEmpty(touser(fv!item)), {}, user(touser(fv!item), "firstName") & " " & user(touser(fv!item), "lastName") ) ) ), readOnly: true, showWhen: a!isNotNullOrEmpty(ri!MDSRequest.requestedonBehalf) ) } ),
If i select two means more than one i am getting below error i selected valid users only still getting this error also before upgrade logic worked after version upgrade i am seeing this can any one suggest on this
Error Evaluating UI Expression Expression evaluation error [evaluation ID = ef19e:da996] in rule 'changerequestsection_display' (called by rule 'caserecorddashboard') at function a!forEach [line 137]: Error in a!forEach() expression during iteration 1: Expression evaluation error at function 'user' [line 145]: [InvalidUserException] (APNX-1-4198-000)
Discussion posts and replies are publicly visible
Seems like there is an invalid username in your list.
two users i added me and other team members we both are active only if i added two users more than one i am getting that error
Is your user account an admin account? Could it be that you do not have permission to see that other user?
Yes I am system admin and other two users whom i added also admins only who were part of my team if i give signle user individually i am not getting this error if i add two users then i can see this error that too observed this after version upgrade only before that there was no issue
OK. I do not have enough information to continue guessing.
If you would be a junior, I would ask how you store the list of users, are all involved variables list types, what data type do you use, do you do any transformation steps, etc.
Thank you went through code found issue and fixed