Have an idea?

Visit Sawtooth Software Feedback to share your ideas on how we can improve our products.

Adapt for radio select

How would I adapt this code to use when each column is a radio select, rather than check 2?

Thanks.
asked Apr 15 by anonymous
You want a grid question to require one, unique radio button to be selected in each column?
Yes. Respondents are selecting a "Most attractive" item from column 1 and a "Least attractive" item from column 2, but we don't want them to be able to select the same item in both columns (most and least attractive must be different items)

1 Answer

0 votes
Try this custom JavaScript verification:

if (SSI_GetValue('[% QuestionName() %]_c1') == SSI_GetValue('[% QuestionName() %]_c2')) {
    strErrorMessage = 'Error';
}
answered Apr 15 by Zachary Platinum Sawtooth Software, Inc. (121,200 points)
This works great. Thank you very much.
...