Restarting a loop & merge block conditional on the answer to a subsequent question | XM Community
Question

Restarting a loop & merge block conditional on the answer to a subsequent question

  • 26 February 2020
  • 5 replies
  • 50 views

Userlevel 1
Badge +1
Hi all,

New to the community, I hope I lay out this question correctly. I suspect I'm in need of some JavaScript since I wasn't able to solve this using branch logic.

Using auto-advance from a timer question, I'm sequentially flashing text on a screen using a loop & merge. After the loop & merge, in the next block, I ask people if they want to watch the loop again.

What I want: If people say "yes" they want to watch again, it should take them to the start of the loop & merge block again. Afterwards, it should once again ask them if they want to watch again. And once again, if they say "yes" it should restart the loop. They should be allowed to re-watch as many times as they like.

The best I can come up with is to, using branch logic, hard code a BUNCH of nested conditional branches (if yes --> show loop block then show "re-watch?" block; then, nested under that, a duplicate block, _ad infinitem_). The problem is that I want them to be able to re-watch as much as they'd like. For some that may be not at all, but for others that could be several or a dozen times.

Any help would be appreciated.

5 replies

Userlevel 7
Badge +22
You can have something similar setup as below, where the Q33 will be a new question you need to add in loop and merge block as first question of this block, and rest all the question will have same display logic as seen in Q34 and Q35

!
Userlevel 1
Badge +1
Hi, @rondev . Thank you SO much.

I think I'm close but can't quite implement. Here's what I tried after adapting your example:
!

The problem: I am presenting the 20 rows of my loop in a random order. With the way that I have it set up currently (pictured above), the "Watch Again" question appears whenever the 20th row of the Loop & Merge table is presented--whether that's at the beginning, middle, or end (depending on the randomization).

Really sorry for not mentioning this quirk in my original posting.

Any thoughts?
Userlevel 7
Badge +27
@wscampbell,

Maybe you can use a table of contents to allow the participant to execute the loop & merge block an unlimited number of times.
Userlevel 1
Badge +1
@TomG

Thanks so much for chiming in. Super appreciated!

Unfortunately, Table of Contents is blocked for my subscription to Qualtrics so that won't work.
Userlevel 1
Badge +1
@rondev

Do you know if there's a way to get ${lm://TotalLoops} (the total loop count) as part of the Display Logic?

I couldn't figure it out.

Leave a Reply