PDA

View Full Version : display negative number if greater then 0



av8tordude
01-03-2011, 05:48 AM
Is there a better way to write this?

If frmPDCalc.EAR.Caption > "$0.00" Then
frmPDCalc.EAR.Caption = Format(.SumIf(Range("B11:B375"), "<=" & CSng(This_Date), Range("F11:F375")), "-$##,###0.00")
Else
frmPDCalc.EAR.Caption = "$0.00"
End If

Bob Phillips
01-03-2011, 06:52 AM
Why do you feel that there is a need to rewrite it, it looks fine.