Skip to main content

How to Migrate a InfoPath List Form to another List Form in SharePoint 2013

I encountered an issue recently where the Info Path form got published accidentally with improper layout.
As we all know that Info Path does not maintain versions and it is impossible to revert to the previous versions.  Luckily I had the back up of the SharePoint list template from where I could open the previous version of the Info path form.

Following are the steps I tried to migrate the Info Path form from the back up to the new SharePoint list.

1. Create a new SharePoint list from the list template.
2. Open the newly created list and click on "Customize form" to open the form in Info path designer.
3. Extract the source files by clicking on File->Publish-> Export Source Files.
4. Update the manifest file with the URL, List ID, Content Type ID of the list to which the Info path form has to be published.

Steps to update the manifest file:

1. Get the List ID from the URL by clicking on List settings. The List Id would be something like List=%7B691FF1A0%2DADB6%2D4032%2DA7CC%2D7E2217E666EB%7D. Now decode the List ID using any URL decoder site or manually to get the List Id in proper format. The decoded List ID would be something like {691FF1A0-ADB6-4032-A7CC-7E2217E666EB}

2. Ensure that the list allows management of Content types and get the content type ID by clicking on the Item Content Type in the list settings page. The content type ID would be something like ctype=0x0100C04093A5341E3C45864A34ED9ED61B66 
The Content Type ID need not be decoded. Take it as it is.
3. Open the manifest.xsf file in notepad and perform the following steps:

        3.1. Find <xsf:extensions>, and change the URL for runtimeCompatibilityURL.  It would be something like runtimeCompatibilityURL="../../../_vti_bin/FormsServices.asmx".  Change the ../ to the full URL of the subsite that holds the list like runtimeCompatibilityURL=”https://<new site>/<new subsite>/_vti_bin/FormsServices.asmx"
        3.2.Change <xsf2:list path="../../../"></xsf2:list> to <xsf2:list path="https://<new site>/<new subsite>/"></xsf2:list>
        3.3.Apply the same change for the line: <xsf3:solutionMode mode="list" originalPublishUrl="../../../" isListEditForm="yes"></xsf3:solutionMode>
        3.4.If it exists, update the URL of this line: <xsf3:baseUrl relativeUrlBase="https://<old site/<old subsite>/Lists/<list>/Item/"></xsf3:baseUrl>

         3.5.Each data connection will have a separate <xsf:dataObject> listing.  Update the siteURL, sharePointListID, relativeListURL parameters of the sharepointListAdapterRW area for each data connection. Please note that here, the relativeListURL is like Lists/<ListName>InfoPath list form manifest.xsf dataobject
         3.6.At the end of the file, there will be a section <xsf:query>.  Update the sharepointListAdapterRW parameters for siteURL, sharePointListID, relativeListURL as well as contentTypeID.InfoPath list form manifest.xsf SharePointListAdapterRW oldHere’s what it looks like after updating.InfoPath list form manifest.xsf SharePointListAdapterRW updated

4.Save and close the manifest.xsf
5. Right click on the manifest.xsf file and click on Design. The template gets opened in the Info path designer. Publish the form. The form gets published to the URL of the SharePoint list where we need to revert or migrate the infopath form from the backup template.

*Note: Above steps are applicable to SharePoint list form and not Form library. In form library, it is possible to directly change the publishing URL.


Happy SharePointing!!! 



Comments

Popular posts from this blog

"An unexpected error has occurred. Changes to your data cannot be saved" excel SharePoint

“If you’re not making some notable mistakes along the way, you’re certainly not taking enough  business and career chances .” After creating a custom "Export to Excel" button on the SharePoint page as in my previous post:   https://nethrasb.blogspot.com/2020/05/export-to-spreadsheet-option-in.html we encountered an issue, where one of the user received "An unexpected error has occurred. Changes to your data cannot be saved" in the excel sheet to which the data has been exported. But I was able to export the data using "System Account" without any issue!  The user has full control over the site and there should not be any permissions related issues.  What could be the issue then?  It might seem silly but this is what happened. Humans make mistakes :) My fellow team mate who had been asked to create the view, created a "Personal" view instead of creating a "Public" view !  "Personal" view is i...

Remove the page title from SharePoint online modern page

SharePoint Online supports two basic designs; The  “Classic”  and the  “Modern”  experience.  The “Classic” experience is a highly customizable user interface much similar to an On-Prem experience.   The “Modern” experience has some limitations on the design customizations unlike the "Classic" experience.  The "Modern" page can be created from Site Contents-> New->Page. The modern page would be created in edit mode where you can choose the page layout and add the necessary webparts and publish the page. But, how to remove the page title from the page where the customizations are limited? It's quite simple!!! 1. Open the page in the SharePoint designer -> "Advanced Edit Mode". 2. Look for the tag <mso:PageLayoutType msdt:dt="string">Article</mso:PageLayoutType>. Replace "Article" with "Home" as below and save the file. <mso:PageLayoutType msdt:dt="string">Home</mso:PageLayoutType> ...

Create a Hyperlink column in SharePoint Online Custom List

“We would accomplish many more things if we did not think of them as impossible.” It is possible to create a hyperlink column in SharePoint list but is it possible to create a hyperlink column as a calculated column? The Answer is "Yesssssssssssssssssss". Following are the steps to accomplish the same. 1. Create a Calculated Column say URL with the formula to link the list column id to a page.  For example: ="http://sharepoint.com/sites/Test/Page.aspx?ID="&ItemID . 2.Create another calculated column say Info and refer the previously created calculated column here in anchor tag. For example:  =IF(ISBLANK(URL),"No URL",("<a href="&URL&" target='_blank'></a>"))  Make sure the data type returned in both the calculated columns are Numbers. Now its time to render the Calculated column as a HTML markup in SPO. 1. Ensure that the list is in the modern experience. 2. Click on the URL column-> Column settings-...