XLS form- Repeat select_one question until "A" is selected

I see now that @RafaelKluender also asked about users changing the repeat question.

As far as I know, there is no way to do this programmatically. There should be conceptually but some quirks of the evaluation engine currently make them impossible:

  • When repeat count is decreased, repeat instances are not deleted. This was a deliberate choice to avoid accidental data loss. The general recommendation is to use a group inside the repeat with relevance testing against the target count to hide repeat instances that are no longer desirable. This means that if the count is adjusted up again, the data will not be lost. This approach doesn't work in this case because of the reasons below.
  • Attempting to use references to values in other repeat instances in a current repeat instance is incorrectly considered a reference cycle.
  • When a value inside of a repeat instance updates, values in other repeat instances are not recomputed. This limitation has always been there and is a performance tradeoff.
  • Relationships between relevance and calculations are incorrectly considered reference cycles.

The latter two probably should be addressed at some point but will likely not be a priority for some time. The first probably is not realistic to address.

I would train data collectors to long press on the label of a question that is in a repeat they accidentally added and then select "Remove Group". This is functionality that is kind of scary and should be used with care but with proper training I think it could solve the issue here.