I need to pipe in text of selected answers as a summary in the next question, but I need to exclude one of the options even if it is selected. Is this possible?
Solved
pipe in text but exclude one option
Best answer by vgayraud
Hi,
Here’s a solution with custom javascript.
- Add a hidden span with class “hideInSummary” to the choices you don’t want to display in the summary.

- Pipe in your results as usual in your summary question, but add this custom javascript code.

Qualtrics.SurveyEngine.addOnReady(function () {
document.querySelectorAll('span.hideInSummary').forEach(span => {
const prev = span.previousSibling;
if (prev && prev.nodeType === Node.TEXT_NODE) {
const content = prev.textContent;
if (content.endsWith(', ')) {
prev.textContent = content.replace(/, $/, '');
}
}
span.style.display = 'none';
});
});
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.





