SSRS Expression

I am trying to make a change in the production detail report in E10.1.500.32
The expression that I am working with is this =IIF(Fields!PONum.Value=0,"",FormatNumber(Fields!PONum.Value,0))

it returns the PO number in the report, but the problem is that the PO number has a comma separator in it.
It should be a whole number EX: 12345 not 12,345

I have tried the properties of the box and set it to no comma separator but that doesn’t change it to a whole number.
is there something in this expression that can take the comma separator out of the number?

https://social.msdn.microsoft.com/Forums/sqlserver/en-US/794be055-1fcd-459b-921a-b8ea93d9b7aa/number-format?forum=sqlreportingservices

Try:
=IIF(Fields!PONum.Value=0,"",Fields!PONum.Value)

1 Like

I believe you change the properties of the text box/placeholder field to be numeric with no separator

Ben,

Thanks for the info, it worked.

Gary

1 Like

Al - I don’t think that would work, as this calculation returns a text string.

It might be possible to not use the calculation at all (just use the Fields!PONum.Value), and set the Text Box Property’s Number type such that it displays a blank for the value 0.

image

I don’t know if this (vs Ben’s solution) result in different renderings - with respect to growing, height, etc…)

duh (forehead slap)
you’re right.
gary specifically stated in the first post - that he already tried the properties
my bad :frowning: pardon my useless info

luckily Ben had the right answer