Support Article
Answer Value does not support special character
SA-86578
Summary
Answer values assigned to a radio type Complex question does not support special characters.
A question is saved with answer values containing special characters and used in the Question Page (QP) assignment. On selecting an option with special characters in the answer value, a refresh occurs and clears the selected option.
Error Messages
Not Applicable.
Steps to Reproduce
- Create Complex radio matrix question.
- Provide Answer values with special character (for example, 'Frequently used 50%'. The '%' is a special character).
- Use this in the Question Page that is displayed to the user as part of the Survey
- Select an option with a special character value.
Root Cause
A defect in Pegasystems’ code or rules :
A Complex radio control (RadioButtonComplexQuestionSurvey) does not allow special characters due to a mismatch between strAnswer and strValue in the Control logic.
Resolution
In the RadioButtonComplexQuestionSurvey control, modify the below line of code,
String strAnswer=myPage.getString(".pyAnswer");
to,
String strAnswer=StringUtils.crossScriptingFilter(myPage.getString(".pyAnswer"));
Alternatively, update to Pega Platform 8.2.3.
Published December 2, 2021
Have a question? Get answers now.
Visit the Collaboration Center to ask questions, engage in discussions, share ideas, and help others.