Skip to main content


 

I worked a support ticket recently that was pretty interesting. The SharePoint list contained two Person/Group columns and when that was appified two People Picker Controls were created on the corresponding SmartForm. Now, as far as when and what happened to cause these two controls to stop returning values we don't know; we did however come to learn that these controls stopped working for different reasons even though they both shared the same behavior.

Control A had a some issue with the service instance and we know that because refreshing the service instance caused control A to start returning values, control B was a little more interesting.

Despite control A working as expected control B still just sat there with a dumb look on its face when asked to return a value. After some head scratching and discussion we noticed something, in a fresh OOB picker control from a newly appified list there is an input property for the control called UserSelectionScope and on a fresh control its value should equal zero. On control B however it was set to 24 and by changeing it to 0 the control began to function as we would expect. Why?

After some research I found that UserSeletionScope is a property of a Person/Group Column on a SharePoint list  and the K2 SmartObject simply inherits it. Whenever the value of this property is defined as 0 we are telling the control to search all the Users associated with the SharePoint site if however we define it as some number greater than 0 like 24 for exemple, then we are telling the control to search all of the Users in the group associated with ID = 24. So effectively we had our control pointed at a group that did not contain our target User(s) and be broadening the scope we were able to catch them.



 
Be the first to reply!

Reply