How to determine the recode value of a displayed choice | XM Community
Skip to main content
Solved

How to determine the recode value of a displayed choice

  • June 26, 2020
  • 1 reply
  • 16 views

Forum|alt.badge.img+6

I have a hidden field that has one displayed choice. How can I figure our the recode value ofthat displayed choice and store it on another hidden field?
For context, I have a hidden multiple choice field (Q1) that randomly displays 1 choice out of a max of 20 choices. I want to store that displayed choice on another variable (Q2) OR auto-select that choice within Q1. At the end of it, I just want that choice saved in the survey data.

Best answer by SurajK

In the JS of Q1, just add the below line and at Q2 pipe the selectedrecode or selected choice as per your requirement.
jQuery('input[type="checkbox"]').prop('checked',true)

1 reply

SurajK
QPN Level 3 ●●●
Forum|alt.badge.img+4
  • QPN Level 3 ●●●
  • Answer
  • June 26, 2020

In the JS of Q1, just add the below line and at Q2 pipe the selectedrecode or selected choice as per your requirement.
jQuery('input[type="checkbox"]').prop('checked',true)