change "total" text on constant sum question to be displayed in different languages | XM Community
Skip to main content

Hello dear community,
I'd like to change the text at the bottom of a matrix constant sum question from "Total" to something different. I learned here that I can do it using this code: on the addOnload function:
jQuery("#"+this.questionId+" .c1:last").html("New Total Label");
The problem is that I am working in a survey in different languages and this "new total label" is not part of the .txt file to upload translations and I can't translate it in different languages.
Any idea would be appreciated.
thanks

Hi,
This solution should work for you:
Make a hidden question, which will also be translated while translating all the other question OR keep the text somewhere universal where you are putting all the piping texts.
Autosum.PNGThen paste this jQuery code in addOnReady in main auto sum question and use the ID of your hidden question here:
var alternateName = "${q://QID268/ChoiceDescription/1}";
jQuery(".Total").html(alternateName);


Archna133 thank you for your reply. It's a good idea.
Unfortunately it doesn't work properly, because it doesn't show the sum. Maybe I did something wrong.
image.png


Leave a Reply