2 Ways to create SharePoint list forms in InfoPath 2010

Learn how you can use InfoPath 2010 or SharePoint 2010 to create an InfoPath form that allows you to view, add, edit, and delete items in a SharePoint list without having to write code.

ADVERTISEMENTS

InfoPath 2010 introduced a new type of form template you can create, a SharePoint List form template.

A SharePoint List form template allows you to create an InfoPath form that is bound to a SharePoint list, and which you can use to view and edit items in a SharePoint list.

There are two ways you can create a SharePoint List form template:

  1. From within InfoPath Designer 2010, when you go to create a new form template, use the SharePoint List form template to base your form template on and then link the template to a new or an existing list in SharePoint.
  2. From within SharePoint 2010, click the Customize Form button on the List tab on the ribbon when you've navigated to a SharePoint list.

Other than these two methods, there isn't another way to link an InfoPath form template to a SharePoint list unless you write code to submit InfoPath form data to a SharePoint list.

If you look on the Data tab under the Submit Form group in InfoPath, you won't find an option To SharePoint List. This is because a SharePoint List form template is a special type of form template that is very similar to the Database form template which you can link up to a database.

For a SharePoint List form template, InfoPath takes care of creating queryFields and dataFields in the Main data source of the InfoPath form for you to be able to query and submit data to the SharePoint list. And therefore, the Main data source is locked from modifications when you create a SharePoint List form template.

Main data source of a SharePoint List form template in InfoPath 2010

Figure 1. Main data source of a SharePoint List form template in InfoPath 2010.

This also means that if you start out creating a normal Blank Form template for example and then afterwards realize that you want to submit the form data to a SharePoint list, you will have to recreate your form template as a SharePoint List form template. Be aware of this and decide beforehand what your form template is going to be used for and how it is going to be submitted before you start designing it.

The SharePoint List form template allows you to either view/edit a single item or multiple items. You can select the latter option when you create a form template from within InfoPath. If you customize a form for a SharePoint list from within SharePoint, you will only be able to customize a SharePoint List form template to view/edit a single item.

So if you want to create a SharePoint List form to view/edit multiple items within a SharePoint list, create this form template from within InfoPath (see method 1 mentioned above).

 
 Subscribe for updates via RSS or Email

Copyright: This article may not be used on web sites (whether personal or otherwise), copied, disseminated, altered, printed, published, broadcasted, or reproduced in any way without an expressed written consent of S.Y.M. Wong-A-Ton. The techniques demonstrated in this article may be used within any Microsoft InfoPath project. This article is provided without any warranties. Copyright for this article is non-transferrable and remains with the author, S.Y.M. Wong-A-Ton.

InfoPath 2013 Cookbook: 121 Codeless Recipes for Beginners
InfoPath 2013 Cookbook 2: 121 Codeless Recipes for SharePoint 2013
InfoPath 2010 Cookbook: 101 Codeless Recipes for Beginners
InfoPath 2010 Cookbook 2: 101 Codeless Recipes for SharePoint 2010
InfoPath 2010 Cookbook 3: 101 Code Recipes for C# Developers
InfoPath 2010 Cookbook 5: Integrating InfoPath with Excel and Excel Services


Related InfoPath Articles:

ADVERTISEMENTS

InfoPath 2013 Cookbook: 121 Codeless Recipes for Beginners

InfoPath 2013 Cookbook 2: 121 Codeless Recipes for SharePoint 2013

InfoPath 2010 Cookbook: 101 Codeless Recipes for Beginners

InfoPath 2010 Cookbook 2: 101 Codeless Recipes for SharePoint 2010

InfoPath 2010 Cookbook 3: 101 Code Recipes for C# Developers

InfoPath 2010 Cookbook 4: 101 Code Recipes for VB Developers

InfoPath 2010 Cookbook 5: Integrating InfoPath with Excel and Excel Services