Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Pulling Only Certain Account Numbers from a Report

Status
Not open for further replies.

NCSue

Technical User
Jun 19, 2015
1
US
I preface my question with the statement that I have only been using Crystal Reports for a week and just started writing reports. There is no one else in this office that has a working knowledge of CR. I am teaching myself as I go. It's much like learning a foreign language from a textbook.

I need to be able to print a report that might have only information from 6 accounts out of 100 on one piece of paper. I can sort and get one account at a time but can't figure out how to specify the accounts I want and have them generate into a printable one page report.
 

1. Create a parameter(right click on Parameter Fields in the Field Explorer and select New).

2. Give it a name - Account Numbers - and make sure the datatype matches the datatype of your account number field - either string or number. Most account numbers are strings.

3. In the Value Options pane, scroll down until you see Allow Multiple Values. Set that option to true. Click OK.

4. In the Select Expert double click the Account Number field. That should open a dialog where you can change the "...is any value" to "is equal to". Then in the dropdown select your parameter field - it should be the first item in the list, and it should be something like {?Account Numbers}.

5. If the parameter field doesn't appear in that list then you have the wrong datatype. Go back to your list of parameters, right click to Edit, then change the datatype field. Then go back to step 4.

Now when you refresh the report the first thing to happen is a dialog asking for parameter values. Enter one or more account numbers and click OK - the report should return data for only those accounts.

This is one of the core concepts of Crystal Reports - create a parameter to collect some information from the user, then use that information to dictate the behavior of the report - usually in record selection, but not always.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top