Search code examples
radio-buttoninfopathinfopath2010

InfoPath 2010 Radio Buttons bound to different fields


I have about 18 radio buttons, each bound to their own field. They are all in the same section. However, a user is able to select more then one of these buttons. I want the user to only be able to select one of these buttons. I know this can be done if they are bound to the same element, but is there a way to do it if they are bound to separate elements?


Solution

  • You're going to have to use either Rules (e.g. Condition: button2 = "1", Rule Type: Action, Run these actions: Set a field's value: . = "0"), or write custom code in a code-behind project.

    Given the amount of buttons involved, I would recommend using custom code (C# or Visual Basic), since you're going to have to setup a lot of rules to manage it all, and it will get very unwieldy, very quickly.