Skip to main content


         This documentation site is for previous versions. Visit our new documentation site for current releases.      
 

Formatting a decimal question in a questionnaire

Updated on March 29, 2022

Help users of your applications provide detailed and accurate answers that require numbers by creating decimal questions. At run time, users can enter numbers that include decimals after a separator to provide very detailed information. As a result, your application can precisely meet even the most specific business requirements.

For example, in a questionnaire about the reimbursement of travel costs, users can provide the precise amounts of their travel expenses.
Before you begin: Add a question of a decimal type to a question page. For more information, see Adding a question to a question page.
Note: Only applications that you build on Cosmos React support decimal questions.
  1. Navigate to the questionnaire:
    ChoicesActions
    Open the questionnaire in App Studio
    1. In the navigation pane of App Studio, click Case types.
    2. In the list of case types, open a case type of the Questionnaire type that you want to edit.
    Open the questionnaire in Dev Studio
    1. In the header of Dev Studio, click ConfigureCase ManagementQuestionnaire.
    2. Click the questionnaire that you want to edit.
  2. If you have multiple questions on the question page, click the question that you want to edit.
  3. In the list of question types, select Decimal.
  4. In the Question settings pane, in the Decimal precision field, enter an integer that reflects how many places after the decimal separator you want users to be able to enter figures.
    For example: To enable users to provide a precise amount of money that includes dollars and then cents, enter 2.
    Result: At run time, users can provide numbers such as 25.55.
  5. For greater clarity, to display a separator in the number, select the Show thousands separator check box.
  6. Click Save.
For example: The following figure shows a decimal question about costs of accommodation with an answer that includes a thousands separator and a two digit decimal separator:
A decimal question at run time
A sample decimal question with a thousands separator and two positions after a decimal separator

Have a question? Get answers now.

Visit the Support Center to ask questions, engage in discussions, share ideas, and help others.

Did you find this content helpful?

Want to help us improve this content?

We'd prefer it if you saw us at our best.

Pega.com is not optimized for Internet Explorer. For the optimal experience, please use:

Close Deprecation Notice
Contact us