Crystal Reports Online Training

Learn Online, Anytime, Anywhere

Step-by-step online tutorials.

4.12 Manually Entering a List of Values

Manually Entering a List of Values

The easiest method of populating the list of values is to manually type each entry. By clicking the Insert button on the Create Parameters window, the cursor is moved to the first available line in the list so you can type in the value. Alternatively, you can also click directly on the next empty line. After entering a value, hit the Enter key to save the value in the list. Repeat this to add as many items as necessary. Every item listed in the Value column appears to the user as one of the default values that they can choose from for that parameter.

Sometimes the items in the Value column are codes or abbreviations for data and the user may not understand what these codes mean. For example, a financial report parameter that specifies a range of revenue account codes might need the value to be formatted in a certain way. But the user has no idea what “50xxx” means. It would be better if they could choose the item “Revenue Accounts” from the list and behind the scenes let the computer take care of the fact that it is really “50xxx”. You can do this with the Description column. The Description column, located next to the Values column, gives you the option of showing descriptions of the values to the user. For values that are somewhat cryptic (e.g. inventory codes), this makes it easy for the user to understand what they are selecting.

Entering a description is optional. If all the values in the list are clear enough, you don’t have to enter a description at all. If some of the values are cryptic, but not all, then you can enter a description just for the ones that need it. And lastly, there can be a description for every value, if necessary.

There are two ways to display the description to the user. It can either be shown next to its value or instead of it. For example, look at the next two figures and compare how the value United States is displayed in each one.




The first figure shows the value, “USA” listed with its description “United States”. But in the second figure you see the description listed by itself. Only showing the description is useful when showing the value could be confusing. The property for doing this is the second item in the Options box below, Prompt with Description Only. Set it to True to only display the description field (this is described in more detail later).

If you want to sort the list of values, simply click on the column header. It automatically reorders the list so that all the items are sorted in ascending order. Clicking on the header again toggles the sort direction to be descending. If you want to sort by description instead of the actual values, click on the description column header.