Parameter with multiple values

Printed From: Crystal Reports Book — Forum Name: Technical Questions

Hi

Can anybody help,How can I use a parameter as an array- having multiple value.
I have created a report and parameter as a serial number but have to pass more than one serial number as an input parameter.



Thanks,
Rashmi
I'm assuming that you mean you have a Parameter field that you can put multiple values in when running the report. Without know exactly what you are looking for I will attempt to give you what I think.

To set up multiple values, when you are creating, or editing, the parameter. In the Value Options change the Allow range values to True. This allows multiple values to be selected.

To filter by this value, when you open the Select Expert - Record, when you select your feild the drop down will show the parameter. You can use this even if you have multiple values. The parameter must be the same data type as the field.

To generate an array from the parameter you can use the following formula.
stringvar array check := {?parameter};
if there is not a way for you list the serial numbers, and even then there is a limit as to how many CR will display, you can use parameter that is tied to a command to query the database and display them for a user to select from.

If this is not an option, and your user knows the serial numbers that they want to report on, you can have them enter multiple values on the parameter and then parse them in the report.

It's a couple of ideas of how to approach a solution.

HTH