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!

Changing all Negative Numbers in a Report to Red 2

Status
Not open for further replies.

wanzek1

Technical User
Jun 13, 2012
79
US
Is there a simple way to change all negative numbers in a report to red? I know that I can write a formula on the formatting of each field but I have a report with 50 plus formulas.

I am really hoping there is an easier way then writing this over and over changing the field:

if Sum ({JCCP.CurrEstCost}, {JCCP.CostType})<0 then crRed else crBlack

Thanks!
 
Unfortunately, that's the only way I know of to do this - a format formula on each field.

-Dell

DecisionFirst Technologies - Seven-time SAP BusinessObjects Solution Partner of the Year
 
What if you use this as the font formula for one of the fields:

[tt]if CurrentFieldValue < 0
then CRRed
else CrBlack[/tt]

Then paint this format using the format painter to all the other formulas that need to be changed. Double-click the format painter to make it 'sticky' and then you just click each field to apply that format. CurrentFieldValue makes it the same for all fields.

Ken Hamady, On-site Custom Crystal Reports Training & Consulting
Public classes and individual training.
Guides to Formulas, Parameters, Subreports, Cross-tabs, VB, Tips and Tricks
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top