pauldes
asked on
change number format in a SQL Report Server expression string
Basically I get how to change the properties of a cell in a SQL Server Report but I can't figure out how to do it when my expression in a cell is not limited to a single field.
Changing the properties of a cell that has an expression like:
="Total NLR USD: " & Fields!NLR_USD.Value
just leaves the number as, well, a number. How can I edit the expression to have the number in "Value" appear as currency.
The result should print:
Total NLR USD: $1,000,000.00 if value = 1000000
Thanks
Changing the properties of a cell that has an expression like:
="Total NLR USD: " & Fields!NLR_USD.Value
just leaves the number as, well, a number. How can I edit the expression to have the number in "Value" appear as currency.
The result should print:
Total NLR USD: $1,000,000.00 if value = 1000000
Thanks
Quickest way is to have:
="Total NLR USD: $" & Fields!NLR_USD.Value
This will work, though will only use $, so it depends if you need to have varying currency formats in your report.
="Total NLR USD: $" & Fields!NLR_USD.Value
This will work, though will only use $, so it depends if you need to have varying currency formats in your report.
ASKER
simon, tried that but the number does not format with commas 1,000,000 prints as 1000000
mjm, I get a build error on your suggestion:
[BC30684] 'Convert' is a type and cannot be used as an expression.
Thanks
mjm, I get a build error on your suggestion:
[BC30684] 'Convert' is a type and cannot be used as an expression.
Thanks
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Thanks!
="Total NLR USD: " & Convert(Money, Fields!NLR_USD.Value)