Display logic on groups | Experience Community
Skip to main content
Solved

Display logic on groups

  • May 18, 2022 1:12 PM UTC
  • 4 replies
  • 216 views

Forum|alt.badge.img+1

Is it possible to do display logic on a group in a "pick, group and rank"-question? I can see, that it's possible on items, but can't seem to find it for groups.

Best answer by TomG

No, there is no display logic for groups in a PGR. You can use JavaScript to hide groups.

View original

4 replies

TomG
Level 8 ●●●●●●●●
Forum|alt.badge.img+27
  • Level 8 ●●●●●●●●
  • Answer
  • May 18, 2022 7:21 PM UTC

No, there is no display logic for groups in a PGR. You can use JavaScript to hide groups.


Forum|alt.badge.img+3
  • Oct 11, 2022 4:21 AM UTC

Hi TomG,
I am a newbie in terms of Javascript. Can you give me an example of the code I would need to use to hide a group that has 15 items.
Thank you in advance


TomG
Level 8 ●●●●●●●●
Forum|alt.badge.img+27
  • Level 8 ●●●●●●●●
  • Oct 11, 2022 12:50 PM UTC

https://community.qualtrics.com/XMcommunity/discussion/comment/50639#Comment_50639Here is an example that hides the last group:
jQuery("#"+this.questionId+" .groupsContainerTd Group").last().hide();


SuhasM
Qualtrics Employee
Forum|alt.badge.img+16
  • Qualtrics Employee
  • Oct 12, 2022 2:29 PM UTC

Thank you TomG for looping back on the thread to provide another single line custom code solution! 👏