@Deepak i created a new post for it. Can you assist me here please?
@Bee
Try below code:
Qualtrics.SurveyEngine.addOnload(function()
{
/*Place your JavaScript here to run when the page loads*/
var n= jQuery("#"+this.questionId+" .InputText").length; for (let i=0;i<n;i++)
{jQuery("#"+this.questionId+" .InputText").eq(i).prop('disabled',true);}
});
Hope it helps!
It Worked! Thank You soo much @Deepak
@Bee
Glad it worked kindly accept the answer.
Hope it helps!
@Bee
Try below code:
Qualtrics.SurveyEngine.addOnload(function()
{
/*Place your JavaScript here to run when the page loads*/
var n= jQuery("#"+this.questionId+" .InputText").length; for (let i=0;i<n;i++)
{jQuery("#"+this.questionId+" .InputText").eq(i).prop('disabled',true);}
});
Hope it helps!
@Deepak this disabled editing of all the three statements in the question. I have a constant sum question where I have a piped in choice for the first option but need the participant to be able to add amounts statements 2 and 3. So, ONLY the number piped in from the previous question should be disabled from editing while the other two are open for entry. How do I edit the script to do that?
@Rajiv Vaidyanathan
In place of n replace it with 1 in code and try. Something like
Qualtrics.SurveyEngine.addOnload(function()
{
/*Place your JavaScript here to run when the page loads*/
var n= jQuery("#"+this.questionId+" .InputText").length; for (let i=0;i<1;i++)
{jQuery("#"+this.questionId+" .InputText").eq(i).prop('disabled',true);}
});
@Deepak
That worked!
Thank you. You are a genius and I greatly appreciate your assistance.