views:

1085

answers:

4

It is a real pain to deploy my InfoPath 2007 Forms from the designer into our development environment's SharePoint server. All of our forms require "full trust" since they include business logic written in C#. Here are the manual steps:

1) Run the "Publish Form" wizard in InfoPath, specifying the target site to publish to and location to save the xsn file.

2) De-activate the existing version of the form from the site collection features (if an older version exists).

3) Log into Central Admin on the development server. Navigate to Application Management -> Manage Form Templates and upload the xsn file.

4) Activate the form as a site collection feature.

Does anyone have an idea how this can be automated? Maybe via stsadm?

+7  A: 

You can package InfoPath forms in SharePoint solutions (WSP files). These can be deployed by making use of STSADM. For more information:

Jan Tielens
Awesome! Thanks for pointing me in the right direction. I found the blog post by Sahil Malik (3rd link in your answer) to be the most concise and easiest process to understand overall.
Saul Dolgin
I wish I knew about this about 18 months ago... :|
Ryan Shripat
A: 

We can build our own service to deploy the InfoPath form in Share point Server. I have developed the service to solve my problem. I have used “STSADM” command to deploy the InfoPath form. You have to understand the STSADM syntax so that you can build the script to deploy the InfoPath form.

Here I have summarized what I did. It may useful for you to start. I developed the web service that will construct the script using STSADM and save it as bat file and run the batch file using Process command available in C#.

guna Samba
A: 

I got the following error after submitting the template via a feature:

This form template is not currently browser-enabled. It must either be republished as a browser-enabled form, or opened using Microsoft Office InfoPath 2007.

Do I have to manually run the InfoPath client publish wizard in order to publish the form template? How can we automate the process?

A: 

Another couple of options are:

1) After running the "publish form" wizard use a batch file with stsadm commands as per the following blogpost: http://sharenotes.wordpress.com/2008/03/18/using-stsadm-to-deploy-upgrade-update-infopath-forms-templates-with-managed-code-behind/

2) Use the InfoPath Form Deployment Tool on Codeplex (or you can simply use the tool to generate the batch files): http://www.codeplex.com/InfoPathFormsInstall

mundeep