on 11-27-2009 9:16 PM
Hello
I am using Crystal Report ver 10. I have three parameter fileds define in my report;
1) Crew (string - values are predefined in history table. They can be more then one)
2) Employee Last Name (string - values are predefined in employee table. They can be more then one)
3) Date Range
I would like to make these parameter fields NOT mandatory. Currently report don't run until I have select or enter data in each of these fields. Is there a way that these fields can become optional and filter data user provided. Any help or suggestion would be greatly appreciated.
Thanks
Syed
Yes, you can make a parameter optional. Please follow following steps:
1. Create a parameter for example "My Parameter". Add a value namely "All" to the values. In the Default Value specify "All" as the default value.
2. Modify the record selection formula as follows:
if {?My Parameter}= 'All' then true else {?My Parameter}={Customer.Country}
Here this report will return all the countries by default when user selects "All" else it will return records for the country selected by the user.
Hope this helps!!
FYI: CR 2008 has a new option which allows to make the parameter optional.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks for your help but this formula did not work. Selecting ALL returns no results to the query. I think because in the database ALL means nothing. Any other suggestions?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
77 | |
8 | |
7 | |
6 | |
6 | |
6 | |
6 | |
6 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.