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

Crosstab highlighting 1

Status
Not open for further replies.

Kibee

Technical User
Sep 30, 2003
16
0
0
AU
Hello there

I am working in Crystal XI and i have built a cross tab to display how many help desk calls were logged for each priority (Summarised Field A) and what percent of them met resolution SLA (Summarised Field B).

Design looks as follows:


Column
Date Resolved (ordered by month)


Row Summarised Fields
Priority Distinct count Field A
Maximum Field B

I am then applying conditional formatting to maximum field B for SLA levels. All ok there.. can use highlighter here or conditional formula based on currentfieldvalue.. ie if currentfieldvalue > 75 then crgreen etc.

PROBLEM:
For some months there are no calls logged.. we have a 0 for summarised field A and a 0 for summarised field B. I also get zeros of course when no calls have met SLA... these two scenarios that return a 0 need to be treated differently

I need to now apply a condition to the highlighting of Field B that refers to Field A as well as field B referring to itself. My aim is to be able to refer to Field A and make field b a nocolor if field A = 0 as i dont want ANY SLA highlighting to occur if there were no calls for that month in that priority.

in normal crysal work (NOT in a Cross tab) i would be able to apply the following conditional formatting to a field b

If {field a} = 0 then crnocolor
else if {field b} > 75 then crgreen
else if {field b} > 50 then cryellow
else crred

can i do this in the cross tab where one summarised field can refer to another in a conditional highlighting formula.

thanks

Kylie





 
Select the summary fieldA->right click->format field->suppress->x+2 and enter:

whileprintingrecords;
numbervar Avalue := currentfieldvalue;
false

Then select the color formula area for fieldB and enter:
whileprintingrecords;
numbervar Avalue;
If Avalue = 0 then crnocolor
else if currentfieldvalue > 75 then crgreen
else if currentfieldvalue > 50 then cryellow
else crred

-LB

 
Hi Ibass

SENSATIONAL... i have just used your code, finished my victory lap around the office and have now come back to say a big thank you.

the concept of using something like supress as simply a space to declare a variable has openned up a whole new train of thought for me.

Thanks again

Kylie

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top