cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Unable to pull data from User Profile service in Nintex Forms in SharePoint 2013  Online (O365)

Add below function in Custom javascript of form settings in Nintex form.

 

 

NWF$(function ()

{

    function getUserProfileInfo() {

        var userprofiles= new SPAPI_UserProfile('<site URL

 

');

 

        var currentUser = userprofiles.getUserProfileByName('i:0#.f|membership|userid);

        if(currentUser.status == 200)

        {

            return currentUser;

        }

        else

        {

            return null;

        }   

    }

   

});

 

Added Js libraries to site library of the SharePoint Online site since I don't have access to _layout folder and included custom js reference it in form settings of Nintex form. As below

 

https://<site URL>/Style Library/SPAPI/SPAPI_UserProfile.js

 

Is the user id passed in the getUserProfileByName correctly . Please let me know

var currentUser = userprofiles.getUserProfileByName('i:0#.f|membership|userid);

 

Tried passing "domain\\userid". But still it does not populate the data?

 

Any help will be appreciable.

Labels: (2)
Tags (1)
0 Kudos
Reply
1 Reply
Workflow Hero

Re: Unable to pull data from User Profile service in Nintex Forms in SharePoint 2013 Online (O365)

discussion regarding it over here - https://community.nintex.com/message/4792?et=watches.email.thread#4792 with unverified solution

0 Kudos
Accept as Solution Reply