user profile values are not populating in the infopath form after publishing it to Form Library in Sharepoint 2010 - InfoPath Dev
in

InfoPath Dev

user profile values are not populating in the infopath form after publishing it to Form Library in Sharepoint 2010

Last post 08-12-2015 08:52 PM by donstephen. 3 replies.
Page 1 of 1 (4 items)
Sort Posts: Previous Next
  • 08-10-2015 10:48 AM

    user profile values are not populating in the infopath form after publishing it to Form Library in Sharepoint 2010

    user profile values are not populating in the infopath form after publishing it to Form Library in Sharepoint 2010

    We have a requirement to prepopulate userinfo fields when the form loads and when the GetInfo button is clicked.

    We use GetUserProfileByName web service to retrieve userinfo fields, such as EmailAddress, Department, Division, Phone Number.

    At Infopath Designer preview, all the userinfo fields are populated as expected. Then I published the Infopath form to the Form Library.

    At browser, the formload only populate logon user's name at the name picker field. Selected a different user and clicked on GetInfo button doesn't populate userinfo fields as well.

    I have checked with a colleague but she uses custom list mostly. She didn't run into this issue.

     What is happening here? The Infopath template is published to a Form library.

    Does the permisison need to be elevated to Full Control to use the GetUserProfileByName webservice with Form library?

    Currently the by default permisison is checked.

    Please help and much appreciated!!

  • 08-11-2015 10:20 PM In reply to

    Re: user profile values are not populating in the infopath form after publishing it to Form Library in Sharepoint 2010

    Hi,

    Using the userName() function in the browser returns a different userName() value in the browser. This explains why there is no value returned.

    Could you try to cross check by publishing a test form and see what the function userName() will return? You could either use a text field or a calculated value box with the userName() as the default value. After doing so, kindly post the value returned here (from the browser) together with the correct userName value in preview mode.

    I'll try to create a formula you could use in order to get the correct value.

    Regards,

    Don Stephen Lambatin / Support Engineer
    Qdabra Software
  • 08-12-2015 08:04 AM In reply to

    Re: user profile values are not populating in the infopath form after publishing it to Form Library in Sharepoint 2010

    I mean the Department, Division, Phone Number, and email address that should fetch values from the WebService is not populated.

    Only the logon user field is populated when the form is published to Form library while all the fields are populated in Preview.

  • 08-12-2015 08:52 PM In reply to

    Re: user profile values are not populating in the infopath form after publishing it to Form Library in Sharepoint 2010

    Hi,

    For cases like this, I would recommed displaying the fields from the GetUserProfileByName data connection onto the canvas, and add a button to query the data connection. If the GetUserProfileByName data is not populated, then the issue would be the userName() function. However, if it does get populated, then you may need to re-structure the logic that specifies the username and performs the query.

    Did you tick the check box at the data connection to query on load? If so, then you may need to disable this and add rules on form load to populate username logic and query the data connection. Hope this makes sense.

    Regards,

    Don Stephen Lambatin / Support Engineer
    Qdabra Software
Page 1 of 1 (4 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.