Using SQLRS 2005
No matter how I format the percentage (using FormatPercent or "P" format
option, my text box in a table control rounds the percentage to a whole
percentage with zeroes in the decimal columns.
I don't want it to round off at all.
Any pointers?
--
John ShahanOn Jan 31, 12:49 pm, jp <j...@.discussions.microsoft.com> wrote:
> Using SQLRS 2005
> No matter how I format the percentage (using FormatPercent or "P" format
> option, my text box in a table control rounds the percentage to a whole
> percentage with zeroes in the decimal columns.
> I don't want it to round off at all.
> Any pointers?
> --
> John Shahan
I am not sure this will help but...
Leave the formatting alone and just use the expression builder
In database column (lets call is percentField), number is like this...
123.456789 then in expression builder '=Fields!percentField.Value +
"%" ' - field should look like 123.456789% on the report.
.123456789 then in expression builder '=(Fields!percentField.Value
*100) + "%" ' - field should look like 123.456789% on the report.
I hope that is what you were talking about and I hope that helps you.
Thanks and have a great day,
Kerrie|||Thank you very much for taking the time to respond.
I tried eliminating the formating as you suggested. And I now have
=Fields!JulPercentage.Value * 100 & "%" as the expression but it is still
taking a value like .026436346 (confirmed by looking at the result set in the
Data tab) and making it 3.00% in the table control on the report.
--
John Shahan
"Kerrie" wrote:
> On Jan 31, 12:49 pm, jp <j...@.discussions.microsoft.com> wrote:
> > Using SQLRS 2005
> > No matter how I format the percentage (using FormatPercent or "P" format
> > option, my text box in a table control rounds the percentage to a whole
> > percentage with zeroes in the decimal columns.
> >
> > I don't want it to round off at all.
> >
> > Any pointers?
> > --
> > John Shahan
> I am not sure this will help but...
> Leave the formatting alone and just use the expression builder
> In database column (lets call is percentField), number is like this...
> 123.456789 then in expression builder '=Fields!percentField.Value +
> "%" ' - field should look like 123.456789% on the report.
> ..123456789 then in expression builder '=(Fields!percentField.Value
> *100) + "%" ' - field should look like 123.456789% on the report.
> I hope that is what you were talking about and I hope that helps you.
> Thanks and have a great day,
> Kerrie
>|||On Feb 1, 4:49 am, jp <j...@.discussions.microsoft.com> wrote:
> Using SQLRS 2005
> No matter how I format the percentage (using FormatPercent or "P" format
> option, my text box in a table control rounds the percentage to a whole
> percentage with zeroes in the decimal columns.
> I don't want it to round off at all.
> Any pointers?
> --
> John Shahan
You can specify the number of decimal places you would like to see in
the percentage, using the
FormatPercent(number, DecimalPlaces) function. However, this will show
zeros if the percent is a whole number. If you want sometimes to show
decimal places, but to show no trailing zeros, then you probably need
to construct the number manually (division, then multiply by 100) and
add the % sign on the end as a string.
Rowen|||On Jan 31, 6:33 pm, "Rowen" <rowen...@.gmail.com> wrote:
> On Feb 1, 4:49 am, jp <j...@.discussions.microsoft.com> wrote:
> > Using SQLRS 2005
> > No matter how I format the percentage (using FormatPercent or "P" format
> > option, my text box in a table control rounds the percentage to a whole
> > percentage with zeroes in the decimal columns.
> > I don't want it to round off at all.
> > Any pointers?
> > --
> > John Shahan
> You can specify the number of decimal places you would like to see in
> the percentage, using the
> FormatPercent(number, DecimalPlaces) function. However, this will show
> zeros if the percent is a whole number. If you want sometimes to show
> decimal places, but to show no trailing zeros, then you probably need
> to construct the number manually (division, then multiply by 100) and
> add the % sign on the end as a string.
> Rowen
I would definitly try Rowan's suggestions, but what do you have the
format as on the table for that field? Something is set and it needs
to be turned off. I would leave it on 'General' or 'g' on the format
property.
Kerrie
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment