locked
infopath 2013 Pulling User's Manager Emails from people/picker RRS feed

  • Question

  • Hello,

    I'm having an issue with pulling others user from different department manager's email through people picker.

    People/picker >String> Button( this button auto populate the selected user's profiles plus manager account) 

    I managed to do it with Data Connection "GETCOMMONMANAGER" , but it'd only work if the current user shares the same common manager or same department.  For an example:

    Current user = Myself

    Select anyone within my department through people picker, it'll auto populate our's manager name & Emails

    IF I select anyone else out side of our department the data connection will not work.

    SO What I stuck with is that, my department is specifically filling out the form for others department.

    I've also tried using GetUserProfilebyName, by pulling the selected user's profile through people picker plus their manager account name.

    Rules:

    Set a field's value:AccountName (GetUserProfileByName(GetManager)) = Manager's AccountName Field

    Query using a data connection: GetManager

    Set's a field value Manager's Name = value(Name = "PreferredName")

    Set a field value Manager Email = value(Name = "WorkEmail")

    These rules successfully pull myself and team members manager's profile

    BUT, if i input other users from different department this came up

    A user with the account name blahblah\ssong  could not be found. ---> An error was encountered while retrieving the user profile.
    <detail><ErrorCode xmlns="http://microsoft.com/webservices/SharePointPortalServer/UserProfileService">UserCannotBeFound</ErrorCode><ErrorMessage xmlns="http://microsoft.com/webservices/SharePointPortalServer/UserProfileService">An error was encountered while retrieving the user profile.</ErrorMessage></detail>

    Please help ! :( 


    Saturday, December 7, 2013 11:28 AM

Answers

All replies