Monday 13 July 2015

Infopath SharePoint 2013 Web Services Form Error 5566


If you are getting a Web Services Form Service Error 5566 when you try to view your form in SharePoint with a query to the User Profile Service, follow the steps below to create your Target Application and update InfoPath.

But First Check the following...


1) Make sure all the data connection files have the environment specific List GUIDs, URLs and so on

2) Make sure all the settings related to InfoPath Forms Services under Central Admin are proper: Enable web service proxy, Enable cross-data connections, Disable Anonymous access

3) Make sure all the relevant user profiles are properly imported under SSP

4) Make sure that the authentication Loopbackcheck registry entry is disabled on the WFE server

5) Make sure the alternate access mappings or managed paths are not breaking the web service calls in the interim


The steps to create this connection are the same as previous version of InfoPath and SharePoint:
  1. Create your data connection to SharePoint by entering in the URL to the web service (where the companyportal section is your web application) http://companyportal/_vti_bin/userprofileservice.asmx
  2. Select the option to GetUserProfileByName and complete the remaining steps in the wizard (leaving the default values is fine)
  3. After the data connection is created you need to convert the connection type to Data Connection file (.ucdx) by clicking on Data connections and choosing the option to convert the connection. The data connection file will need to be published to a Data Connection Library within your SharePoint site.
  4. After you publish the Data Connection file to your library, you need to download a copy of the file so that you can make the necessary adjustments.
  5. Before you proceed with the next steps, you must also make sure that you have a Target Application created within your Secure Store Service that is set to use a service account that has permissions to query the User Profile Service. In my case, I used my Central Administration Account.
  6.  After you create your Target Application, make note of the name of the Target Application ID you created in Central Administration.
  7. Open up the UCDX file that you downloaded from your Data Connection Library using Notepad
  8. Look for the section towards the bottom where you can uncomment the <!—UDC:Authentication> section by removing the !—after the left and right brackets. Add the name of your Target Application ID in the SSO AppID section and NTLM in the Credential Type as shown below
    <udc:Authentication>
    <udc:SSO AppId=’UserProfileService’ CredentialType=’NTLM’ />
    </udc:Authentication>
  9. Save, close and upload the new modified UDCX file back into your data connection library.
  10. Proceed with the steps to set default values for your fields or add rules upon form load to set default values for your fields in InfoPath that you wish to populate with data from SharePoint.
  11. Steps on how to populate forms can be found on the following blog post.  This was written for SharePoint 2010 but has all of the steps needed. http://blogs.technet.com/b/anneste/archive/2011/11/02/how-to-create-an-infopath-form-to-auto-populate-data-in-sharepoint-2010.aspx

No comments:

Post a Comment