In java-script code for the first question of the survey, I added following line, to initialize the counter:
localStorage.setItem("question_cnt", "0")
Also, in the survey flow, I set the value of the embedded field to "Piped Text". (I am assuming this will allow me to update the value using java-script)
However, when I insert "${e://Field/question_cnt}" in my questions text, the value of the counter does not appear in the preview.
(In my question, I have an image following the question text, which I am not sure if it is contributing to the problem or not).
Am I missing something?
Best answer by Anonymous
View original