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

HI @LN et al.,

I'm writing to ask about a small wrinkle in this elegant example...in our form the question that triggers adding another repeat group is this: Was that the final household in this multi-family dwelling? (A response of `no' means we should add another group (household) and 'yes' means we should drop out of the repeat and get ready to finish the form; 'yes' is analogous to stopping condition 'a' from your example.)

The problem we run into is when someone MISTAKENLY says 'no', thinking they need to do an additional interview. They tap 'no' and swipe forward; the repeat counter increments and a new group is added. If they swipe back and change 'no' to 'yes' ( 'b' to 'a' ) and swipe forward again, presumably the repeat count logic does not increment the counter yet again, but it's too late...aargh...repeat count has already been incremented after the first 'b' and swipe-forward. So the form takes the interviewer on an extra faux trip thru the repeat...(at which point some of them get creative in trying to save and abort the form).

Is there a sweet way to decrement the repeat counter if the user swipes back into the bottom of the previous repeat and changes 'b' to 'a'?

Many thanks,
-Dale & @marykaytrimner