June 24, 2021

How to get User Information in InfoPath form using User Information List with SharePoint Online


Introduction

We recently migrated InfoPath Forms from SharePoint On-Premises to SharePoint Online for a Postal and Parcel company based out of Melbourne, Victoria, Australia. In this migration, we updated all the data connections of the InfoPath Forms for compatibility with SharePoint Online. 

So, in this blog, we will explore one of the data connections and will learn how to get User Information in InfoPath form using User Information List with SharePoint Online (Office 365).

User Information List

User information list is the SharePoint list that stores all the user information details. So, we will directly use this list and get user’s details.

Steps to get the Users information.

Step 1: Open your InfoPath form in InfoPath Designer. Open “Data Connection”, you can open data connection with two way.

1.      Open from “Data” tab

2.      Directly, click on “Manage Data Connection” in bottom right corner of the field panel.


Step 2: After opening the “Data connection”, click on the “Add” button.


 Step 3:   Once you click on the “Add” button, it will open a new “Data Connection Wizard and select “Create new Connection to:” and “Receive data” and then click on the “Next” button.  


Step 4:  Then select “SharePoint library or list” and click on the “Next” button.

Step 5: Enter your Site URL in the textbox and click on the “Next” button.


Step 6: Select the last “User Information List” from the list and click on the “Next” button.

 Step 7: It shows all user information columns. Select the checkbox based on your requirement and click the “Next” button.

Step 8: In the next window select the “Next” button.

Step 9: Next window enter your connection name, select “Automatically retrieve data when  form is opened” and click on the “Finish” button, “Connection Wizard” will be closed automatically.

                          

Step 10: In "Data Connection Wizard" a new connection will be displayed, close the window now.

Step 11: To view User Information select "User Information Connection" from the "Fields" panel.

                  Scroll drop-down and select the "User Information List".


Step 12: Then expand the "data field" and right-click on "d: SharePointListitem_Rw" folder and select "Repeating Table".


Once you select, the table appears in your form and once you click on preview, it will show all user Information.

Final Output

Here User's Full name, Login name, and ID is been displayed.

Based on your requirement, you can retrieve particular user information also, currently it will show all users.


If you have any questions you can reach out our SharePoint Consulting team here.


June 17, 2021

[Resolved]: Different issues and their solutions while publishing InfoPath form to SharePoint Online environment.

        Introduction

        We performed the migration of the InfoPath forms from SharePoint On-Premises to the SharePoint Online environment using InfoPath designer for a Postal and Parcel company based out of Melbourne, Victoria, Australia. Wupdated the InfoPath form as per the online version, but when we start publishing the form, we encountered some issues.

        In this blog, we will learn about these issues and the solutions which we encountered while publishing the InfoPath form. 

        Scenario

          • We had an InfoPath form with multiple data connections. 
          • First, we changed the data connections according to SharePoint online environment then we publish the form to a SharePoint library but when we tried to publish the InfoPath form for the first time, we faced and resolved these issues. 

          Issues and Solutions

          Problem 1: 

          • When we publish the InfoPath form at the end of the Publishing wizard it shows an alert box as “InfoPath cannot save the following form: form name. This document library was either renamed or deleted... 
          • This issue was detected when we tried to publish the form for the first time.
          • The issue is "The library is either renamed or deleted..." even if the library is correct in SharePoint online.
           

          Solution: 

          • To resolve this issue, we need to make changes to the server from where we are trying to publish the InfoPath form template. 
          • We have to add the "Desktop Experience" feature in the server manager. 
          • The issue occurred because the "Desktop Experience" feature is responsible for the connection between the SharePoint server and the window server while publishing an InfoPath form and it was not installed in our system. 

          Steps to add the "Desktop Experience" feature

          Step 1: 

          Open server manager and click on the "Managetab from the top ribbon and choose the "Add Roles and Features" option as shown below. 


          Step 2: 

          • It will open the “Add Roles and Features Wizard”. 
          • Here, in the "Features" section we have to expand the "User Interface and Infrastructure" and select the "Window Experience" feature and after completing the steps of this window we need to restart our server. 


          Now the error will be resolved and we will be able to publish the InfoPath form.

          Problem 2  

          Sometimes we detect this issue. 
          • When we publish the InfoPath form, at the end of the Publishing wizard it shows an alert box as InfoPath cannot save the following form: form name. Access Denied...". 
          • This issue occurs when we try to publish the form for a site that is not a trusted site in our system. 


          Solution: 

          • To resolve this issue, we have to add the targeted site to the "trusted sites". 

          Steps to add a site to the trusted sites  

          Step 1: 

            Open the  Internet Explorer and click on the "Internet Options" as shown below.
             

            Step 2: 

            • Click on the "Security" tab, then open "sites" as shown below. 
            • It will open a window where we can add our site and make it a trusted site.

            Now the error will be resolved and we will be able to publish the InfoPath form.

            Conclusion: 

            This is how we can resolve these issues and publish the InfoPath forms successfully. Hope this will help you.

            If you have any questions you can reach out our SharePoint Consulting team here.