Thursday, May 26, 2011

Formatting RDL/RDLC values as percentage

I thought I'd share how to format percentage values in ReportViewer report.
Say your data source has the following fields:
  • TotalLow
  • TotalHigh
  • Total

Suppose we want to display the values for TotalLow and TotalHigh as  percentage of Total.

We can use the following expressions.

You notice the RDL/C allows you to use .NET String object Format method.

Hope this helps.

No comments: