How to Deploy an InfoPath 2007 Form Containing Managed Code to a Browser-Enabled WSS v3 Library

Update (8-14-2006): InfoPath Forms Services is NOT part of WSS v3.  It is a separate install, or you can install it as part of the MOSS 2007 Beta 2 install.  The RTM version, last I heard, will be available as a separate SKU or as part of MOSS 2007 Enterprise Edition.

Assuming you have already created an InfoPath form containing managed code, this document will explain the steps necessary to deploy it to a WSS form library that is “web-enabled” by InfoPath Forms Services.

Publish the Template to the File System (or file share)

Note: In Office 2007 you can’t publish an InfoPath form containing managed code directly to a WSS form library because it has to be first approved by a WSS Administrator.

  1. Open the Design Tasks task pane and choose Publish Form Template. 

  2. Choose the first option, to publish to SharePoint, and click Next. 

  3. Enter the location of the SharePoint site you want to publish to. 

  4. You will be presented with the screen below.  Make sure the checkbox is checked to enable the form to be filled out in a browser and click Next.

  5. You must choose a location to save the template file, which will be uploaded to the SharePoint site by the site administrator.

  6. Specify any columns you want to be made available as WSS columns in the form library.

  7. Verify that the information is correct and click Publish. The form will be published to the specified file share location.

Upload the Template to the Central Administration Form Templates Library

  1. Go to the Central Administration site for your farm (or web server if there's only one) 

  2. Click on the Application Management tab, go down to the InfoPath Forms Services section, and choose Manage Form Templates. 

  3. The Form Template library is opened, which is where admin-approved form templates for the farm are stored. 

  4. Click Upload Form Template.  Choose your saved template file and click the Verify button.  You will be shown any errors or warnings related to your template file.  Read any warnings (hopefully there are no errors) and click OK. 

  5. Choose your template file again (Why is it not persisted in the text box between postbacks??).  In the Upgrade section, you can choose to upgrade the form template if it already exists.  You can also choose how to handle current sessions that are using the form template. 

  6. Click the Upload button to upload the form template.  It is now available as a Feature to be activated on any site collections in the farm. 

Activate the Form Template on a Site Collection

  1. You can activate a form template feature from the Manage Form Templates page of Central Administration (the same page where you uploaded the template).  On the context menu of the newly uploaded form template, choose Activate to a Site Collection. 

  2. In the Activation Location section of the page, choose the appropriate Site Collection and click the OK button. 

Note: You may actually have to change Web Applications to find the site collection you are looking for.  A Web Application maps to an IIS virtual server.

Associate the Form Template with a Form Library

  1. Create a new form library (or use an existing one, it really doesn't matter),go to the settings page. and choose Advanced Settings. 

  2. Choose Yes for Allow management of content types.  For Opening browser-enabled documents, choose Display as a web page. 

  3. Click the OK button to go back to the Form Library Settings page. 

  4. There should now be a Content Types section which displays the Content Types enabled for the form library.  The form template feature that you activated added a new content type to the Site Content Type Gallery.  

  5. Choose Add from existing site content types and find your form template.  Click on it and click Add, then click OK. 

  6. Go back to your form library, click the New dropdown, and choose your form template.  It will be opened in the browser window where it can be filled out and saved or submitted.

This article is part of the GWB Archives. Original Author: Josh Meyer

New on Geeks with Blogs

  • We Won The One Award I Actually Care About

    Full Scale made the Inc. 5000 for the fifth year straight, the 12th listing across my three companies. Here is why the one award you cannot buy is worth stopping for.

  • Your Customers Build the Features Now

    I let a tool I liked sit dead for a year rather than build the features I wanted. An MCP server meant I never had to, and your customers can do the same to your product.

  • Get the Size of a Directory in Linux the Easy Way

    du -sh for the quick answer, ncdu for the cleanup, df for the disk itself: every command for checking directory size in Linux, plus why du and df never agree.

  • Vim Search and Replace: The Ultimate Guide

    One :%s command replaces every match in a file before a find dialog would even open. The Vim substitute patterns worth the muscle memory: flags, ranges, capture groups, and multi-file edits.