- Posts: 22
- Thank you received: 0
Welcome to the LimeSurvey Community Forum
Ask the community, share ideas, and connect with other LimeSurvey users!
How to make a autocode question as read only?
- BOBYJAMES
- Topic Author
- Offline
- Junior Member
Less
More
2 years 11 months ago #216533
by BOBYJAMES
How to make a autocode question as read only? was created by BOBYJAMES
Hi,
we have 2 questions in a survey
1, What is your age?
Ans. 26
2, Age group (autocode age group)
Ans.
* below 20
* 20 - 25
*26 - 30
*31 - 35
*above 35
Here the answer of seconed question is autocode as 26-30, but still the user can edit this. How to set this question as read only status ?
Thanks in advance
Kindly please help...
we have 2 questions in a survey
1, What is your age?
Ans. 26
2, Age group (autocode age group)
Ans.
* below 20
* 20 - 25
*26 - 30
*31 - 35
*above 35
Here the answer of seconed question is autocode as 26-30, but still the user can edit this. How to set this question as read only status ?
Thanks in advance
Kindly please help...
The topic has been locked.
- jelo
- Offline
- Platinum Member
Less
More
- Posts: 5033
- Thank you received: 1257
2 years 11 months ago - 2 years 11 months ago #216535
by jelo
The meaning of the word "stable" for users
www.limesurvey.org/forum/development/117...ord-stable-for-users
Replied by jelo on topic How to make a autocode question as read only?
What version of LimeSurvey is used? Since we don't know how the autocode question is implemented, it's not possible to provide a solution. Without any information I would try to hide the question via CSS.
forums.limesurvey.org/forum/can-i-do-thi...ith-relevance#155904
forums.limesurvey.org/forum/can-i-do-thi...ith-relevance#155904
The meaning of the word "stable" for users
www.limesurvey.org/forum/development/117...ord-stable-for-users
Last edit: 2 years 11 months ago by jelo.
The topic has been locked.
- BOBYJAMES
- Topic Author
- Offline
- Junior Member
Less
More
- Posts: 22
- Thank you received: 0
2 years 11 months ago #216538
by BOBYJAMES
Replied by BOBYJAMES on topic How to make a autocode question as read only?
Hi,
Lime survey version - Version 3.15.5+181115
Autocode is done by this way-
in Question validation equation: S2=if(S1.NAOK < 20, "1", if(S1.NAOK >= 20 && S1.NAOK <= 25, "2", if(S1.NAOK >= 26 && S1.NAOK <= 30, "3", if(S1.NAOK >= 31 && S1.NAOK <= 35, "4", if(S1.NAOK >= 36, "5"))))))
just need to set this question as read only..
Thanks in advance
Lime survey version - Version 3.15.5+181115
Autocode is done by this way-
in Question validation equation: S2=if(S1.NAOK < 20, "1", if(S1.NAOK >= 20 && S1.NAOK <= 25, "2", if(S1.NAOK >= 26 && S1.NAOK <= 30, "3", if(S1.NAOK >= 31 && S1.NAOK <= 35, "4", if(S1.NAOK >= 36, "5"))))))
just need to set this question as read only..
Thanks in advance
The topic has been locked.
- Joffm
- Away
- LimeSurvey Community Team
Less
More
- Posts: 12938
- Thank you received: 3979
2 years 11 months ago #216542
by Joffm
Volunteers are not paid.
Not because they are worthless, but because they are priceless
Replied by Joffm on topic How to make a autocode question as read only?
Hi,
if it is to be "readonly", why do you show it at all (as jelo)?
Here you only define some age brackets.
And if you really want to show his age bracket to the respondent, do it in a question of type "text display".
Two more things:
2. You do not understand the logic of the IF function quite well.
You see, all your ">=" parts are not necessary; because they are always TRUE; otherwise these parts were not reached.
S2=if(S1.NAOK < 20, "1", if(S1.NAOK <= 25, "2", if(S1.NAOK <= 30, "3", if(S1.NAOK <= 35, "4", "5")))) is sufficient.
Joffm
if it is to be "readonly", why do you show it at all (as jelo)?
Here you only define some age brackets.
And if you really want to show his age bracket to the respondent, do it in a question of type "text display".
Two more things:
1. in Question validation equation? Usually you do this in a question of type "equation"in Question validation equation: S2=if(S1.NAOK < 20, "1", if(S1.NAOK >= 20 && S1.NAOK <= 25, "2", if(S1.NAOK >= 26 && S1.NAOK <= 30, "3", if(S1.NAOK >= 31 && S1.NAOK <= 35, "4", if(S1.NAOK >= 36, "5"))))))
2. You do not understand the logic of the IF function quite well.
You see, all your ">=" parts are not necessary; because they are always TRUE; otherwise these parts were not reached.
S2=if(S1.NAOK < 20, "1", if(S1.NAOK <= 25, "2", if(S1.NAOK <= 30, "3", if(S1.NAOK <= 35, "4", "5")))) is sufficient.
Joffm
Volunteers are not paid.
Not because they are worthless, but because they are priceless
The topic has been locked.
- BOBYJAMES
- Topic Author
- Offline
- Junior Member
Less
More
- Posts: 22
- Thank you received: 0
2 years 11 months ago #216544
by BOBYJAMES
Replied by BOBYJAMES on topic How to make a autocode question as read only?
Thank you joffm for the explanations
The topic has been locked.