What is the correct JS code for calling out statements within a Matrix Table? | XM Community
Skip to main content
Question

What is the correct JS code for calling out statements within a Matrix Table?

  • February 26, 2021
  • 3 replies
  • 55 views

We would like to customize the statement text within our matrix table using JS code based off of a previously answered question in the survey. We were able to customize the question text using "qc.innertext" but I was wondering if there's a line of code to do the same for the statements within a matrix table set.
Here is the code line we used for the innertext:
qc = this.getQuestionContainer().querySelector(".QuestionText");
Role = "${q://QID2/ChoiceGroup/SelectedChoices}";
if (Role == "Student") {
qc.innerText = "Students in my concentration connect with me";


Thanks!

3 replies

Forum|alt.badge.img+22
  • Level 7 ●●●●●●●
  • February 27, 2021

Why aren't you using carry forward choices for this?


  • Author
  • March 1, 2021

ahmedA
Will the data be grouped together with carry forward choices? I would like to group the data together in the Report.


Forum|alt.badge.img+22
  • Level 7 ●●●●●●●
  • March 1, 2021

I don't know what "group the data" means.