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

Xtab conditional formatting 1

Status
Not open for further replies.

cjbrown815

IS-IT--Management
Mar 2, 2006
525
US
Hello,
I have a Xtab report that displays 3 different method results (Yeast, Mold and Coliform)

Rows = SAMPLE.DATE1 (DATE)
Columns = @Sort column , @ID and Desc ({SAMPLE.SAMPLE_TYPE} + "=" + {SAMPLETYPE.ST_NAME})
Summarized Fields = Max of SAMPLEPARAM.SRESULT (String)

Conditional Formatting Formula
if val(currentfieldvalue) >= 10 or
currentfieldvalue = "TNTC" or
currentfieldvalue like ">*" then crRed else
if currentfieldvalue = "NR" then crBlue else
crGreen



I need it to display results in red when the coliform is >0 and the yeast or mold is >9

Right now its putting anything greater then 9 in red.


thanks


-CJ

SQL2005// CRXIr2// XP Pro

"Progress lies not in enhancing what is, but in advancing toward what will be"
-KHALIL GIBRAN 1883-1931
 
if
(
gridrowcolumnvalue("@ID and Desc")="123Coliform" and
val(currentfieldvalue)>0
) or
(
gridrowcolumnvalue("@ID and Desc")="456Mold" and
val(currentfieldvalue)>9
) or
val(currentfieldvalue) >= 10 or
currentfieldvalue = "TNTC" or
currentfieldvalue like ">*" then
crRed else
if currentfieldvalue = "NR" then
crBlue else
crGreen

-LB
 
WOW did I get this one wrong. I'm not quite sure about the logic behind the "123Coliform" and the "456Mold", it works but I dont understand how :)

As always, thanks LB

-CJ

SQL2005// CRXIr2// XP Pro

"Progress lies not in enhancing what is, but in advancing toward what will be"
-KHALIL GIBRAN 1883-1931
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top