I have an infopath form, where several fields exist. Everything is fine with textbox fields, but there is some trouble with people picker field. I can pre-assign initial value for these field, but when I edit, it doesn't store the new value. Can anybody tell me, what is the problem? Or maybe you can provide with some links, because I didn't find a solution for such kind of a problem.
To successfully set the value of a people picker field, you have to correctly populate all three fields: DisplayName, AccountId, and AccountType. AccountType is either "User" or "Group", but the other two have to align with your AD or wherever you're getting your user data from. That's pretty straightforward if you are always going to be a single user or group. If you need to dynamically assign a people picker, use a function like this to assign each value explicitly: