Choice field with maximum selections in InfoPath 2010
Learn how to create a group of check boxes and allow users to select a maximum of choices on an InfoPath 2010 form.
You have an InfoPath 2010 form with check box controls (choice fields) on it and you want to allow users to select a maximum amount of choices from those check boxes.
For example, if you have a group of 5 choice fields (check boxes), you want users to be able to select no more than 3 choices out of the 5.
An easy way to present a group of choices is to place a choice field in a repeating group. And then to allow users to select a maximum amount of choices from the group of choices, you can use data validation on the choice field.
And to pre-define a fixed amount of choices (for example 5 check boxes), you can use the Default Values command in InfoPath 2010 and remove the ability to add rows to the repeating table.
Once you have the controls in place on the InfoPath form template, you can add InfoPath data validation to the check box within the repeating table to prevent users from adding more than a preset amount (3 in this example) of choices from the group of check boxes.
The following InfoPath 2010 tutorial video shows how to set up data validation on a check box in a repeating table to create a group of check boxes from which a maximum of 3 choices can be selected.
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.
Related InfoPath Articles:
- How to pre-fill a repeating table in InfoPath with rows of data
- InfoPath choice section and choice group controls
- Repeating table vs. repeating section in InfoPath
- Multi-select list box to show/hide columns in horizontal repeating table
- Limit a multi-select list box to a maximum of 3 selected items