Unable to deploy InfoPath Admin Approved Template to CA in SharePoint 2019

Philip Victor Jebaraj S 41 Reputation points
2020-08-27T19:05:36.32+00:00

Hi Team,

I am working in SharePoint 2019 migration project. I am in the position to migrate InfoPath 2007 form to SharePoint 2019. The InfoPath 2007 form was developed with managed code (c#) and deployed as an admin-approved template. In 2007, the forms were deployed in Central Admin and uploaded to FormServerTemplates library.

I made the following approach to migrate the InfoPath form, but the converted forms are not deployed to the Central Admin in SharePoint 2019.

  • Open the InfoPath 2007 form template in InfoPath 2013
  • Export Source Files to the folder
  • Updated the site collection URL in the manifest.xsf file from the extracted folder
  • Downloaded all UDCX Files from SharePoint 2007 Data Connections library and updated WebUrl & ListId (GUID)
  • Uploaded the updated UDCX files into SharePoint 2019 Data Connections library
  • Opened the command prompt and navigated to the extracted source files folder
  • Ran the command "dir /a-d /b > ../cabfiles.txt"
  • Updated the cabfiles.txt file like below

20973-cabfiles.png

  • Ran the command "makecab.exe /f cabfiles.txt". It is generated the XSN file in the specified path which is mentioned in the cabfiles.txt file.
  • Open the generated xsn file in design mode. Verified the data connection and it is pointed to the new site (SP 2019)
  • Set the Full Trust under Security and Trust in Form Options
  • Set Compatability as Web Browser Form (Initially, Web Browser Form (InfoPath 2007))
  • Publish the form
  • Selected the target site
  • Checked Enable this form to be filled out by using a browser checkbox.
  • Selected Administrator-approved form template (advanced) option button
  • Choose the local path to save the template.

Created SharePoint 2019 Empty Project in Visual Studio 2019 and did the following.

  • Added Feature in the existing Feature folder
  • Added Module as a new item into the project
  • Delete the Sample.txt file
  • Added the published xsn file and dll (InfoPath code behind dll) file into the module folder
  • Updated the Elements.xml file as below

21022-elementsxml.png

  • Updated the Feature.xml file as below

20969-featurexml.png

  • Generated the WSP and deployed to the site and activated the Feature
  • XSN file is uploaded to the FormServerTemplates library, but it is not uploaded to the Central Admin
  • When I try to open the xsn file from FormServerTemplates, it throws an error as "This form cannot be opened in a Web browser. To open this form, use Microsoft InfoPath".

Please provide the solution to overcome these errors and open the admin approved InfoPath template in SharePoint 2019.

SharePoint Server Development
SharePoint Server Development
SharePoint Server: A family of Microsoft on-premises document management and storage systems.Development: The process of researching, productizing, and refining new or existing technologies.
1,599 questions
{count} votes