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 TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

dynamic grouping

Status
Not open for further replies.

ceccina

IS-IT--Management
Nov 18, 2002
22
IT
Hi!
I'm using CR 9. I create a parameter to choose data field for grouping and a formula like this:
if {@group = 'A'}
then {field A}
else {field B}
I placed this formula in report header and suppress it from viewing (as in on-line help).
I grouped my data on this formula, but the result is that data are always order by filed B. I'm sure the parameter is correctly initialized with 'A'. [mad]
Can you help me?
 
Your condition:
----------------
if {@group = 'A'}
then {field A}
else {field B}
----------------
is referring to the Group formula instead of the Parameter.

Use:
----------------
if {?group_by_parameter} = 'A'
then {field A}
else {field B}
----------------

Cheers,
- Ido CUT, Visual CUT, and DataLink Viewer:
view, e-mail, export, burst, distribute, and schedule Crystal Reports.
 
Thanks! The solution is always in front of your eyes!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top