Welcome to the LimeSurvey Community Forum

Ask the community, share ideas, and connect with other LimeSurvey users!

Circumventing "Self" in questions

More
8 years 10 months ago #142971 by g3guy
Hi

I'm experiencing a problem when I use the word "self" in questions given it being a "reserved" question, do I use an escape character?

Example:


The actual text should state - "Displays emotional self-control in times of high pressure".

Thanks!
The topic has been locked.
More
8 years 10 months ago #142978 by DenisChenu
You surely have some bracket somewhere : www.limesurvey.org/manual/Expression_Manager
Or you put it somewhere where EM is used directly.

Strange : because Display emotionnal must show in red ....

Can you detail the process ?

Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member. - Professional support - Plugins, theme and development .
I don't answer to private message.
The topic has been locked.
More
8 years 10 months ago #142985 by g3guy
Hi Denis

This is my expression:
Code:
{if(TOKEN:ATTRIBUTE_1=='Self','I display emotional self-control in times of high pressure','Displays emotional self-control in times of high pressure')}

Resulting in the "reserved" word kicking off and showing up that error.
The topic has been locked.
More
8 years 10 months ago #142987 by tpartner
I see that as a bug. Anything in quotes should be parsed as a text string, not a variable name. Please file a bug report.

As a workaround, try loading TOKEN:ATTRIBUTE_1 into an equation question and then reference that in your expression.

Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
The topic has been locked.
More
8 years 10 months ago #142989 by g3guy
Thanks Tony - will do so! (will be my first bug report)

Actually, my workaround was quite simple - I just capitalised the "S" - so "Self-control" works fine. Although it just jars the respondent's reading though.
The topic has been locked.
Moderators: tpartnerholch

Lime-years ahead

Online-surveys for every purse and purpose