0

I'm having troubles using an expression in one on my textboxes. I need all null values to display as 0, which I have done correctly. However, if the number is a decimal, say 126.5000, I need it to just display as 126. I was thinking about using the FIX function like so...

=IIF(IsNothing(Sum(Fields!PROP__QTY.Value)), "0", Fix(Sum(Fields!PROP__QTY.Value)))

however when I do that I get #ERROR where the 0's should be displayed. The fix function works though. If I take the Fix out, then the 0's display proper as well. Is my syntax not correct? I'm fairly new with SSRS so any guidance would be awesome. Thanks!

AdamK
  • 63
  • 8

1 Answers1

0

You appear to be mixing types try , 0 , rather than , "0" , as this changes it from a number to text

I personally would use CInt to convert the result rather than Fix =IIF(IsNothing(Sum(Fields!PROP__QTY.Value)), "0", CInt(Sum(Fields!PROP__QTY.Value)))