For a customer I recently worked out a proof of concept with some InfoPath forms and some simple workflows.
On the SharePoint environment I had to show my forms, there was no InfoPath 2007 available and I also didn’t have administrator permission to go the central admin site.
As far as I knew, there were 3 ways to deploy an InfoPath form:
- To a SharePoint Form Library. (Requires direct access to the SharePoint environment from Infopath 2007)
- As a SharePoint content type. (Requires direct access to the SharePoint environment from Infopath 2007)
- As an administrator-approved form template. (Requires permissions to the central admin site for deploying the form template)
None of these 3 ways were convenient for me since my InfoPath didn’t had a connection to the SharePoint environment and I only had permissions within a given site collection.
I came up with a 4th way to deploy an InfoPath form without having to write any code!!
On my development machine on which I have SharePoint 2007, InfoPath 2007 and of course full control, I deployed my InfoPath form directly to a form library (the easiest way). From this form library I created a “List template” (an .stp). Next, I uploaded this .stp file to the list gallery on the SharePoint environment I needed to show the proof of concept on. Created a new library based on my custom list template and my form library with InfoPath form was deployed and worked!!
Actually, not the first time. Make sure your development environment and the environment you’re deploying to have the same language pack. Otherwise your uploaded list template isn’t available in the list of available library templates. This was the case for me. I took a wild shot and opened the .stp file (by renaming it to .cab). Extracted the manifest.xml file and the .000 file and replaced all 1033 (English) references in the manifest.xml to 1043 (Dutch). Then I created a very simple .ddf file and used MakeCab.exe to create a new .stp file. Remarkably, when I uploaded this list template, it all worked!