[Expand]General Information
[Expand]WinForms Controls
[Expand]ASP.NET Controls and MVC Extensions
[Expand]ASP.NET Bootstrap Controls
[Expand]ASP.NET Core Bootstrap Controls
[Expand]WPF Controls
[Expand]Xamarin Controls
[Expand]Windows 10 App Controls
[Expand]Office File API
[Expand]Reporting
[Collapse]Report and Dashboard Server
 [Expand]Installation
  License and Distribution
 [Expand]Administrative Panel
 [Collapse]Create Reports
  [Collapse]Web Report Designer
    Create and Customize Reports
    Bind a Report to Data
    Construct the Report Layout
    Calculate Custom Values
    Specify Data Formatting
    Customize the Report Appearance
    Apply Conditional Formatting
    Sort and Group Report Data
    Calculate a Summary
    Add Additional Information
    Add Parameters and Filter Data
    Provide Navigation to the Report
    Provide Interactivity to the Report
  [Expand]Windows Forms Report Designer
 [Expand]Create Dashboards
 [Expand]Configuration and API
  User-Specific Functions
  Localization
[Expand]Dashboard
[Expand]eXpressApp Framework
[Expand]eXpress Persistent Objects
[Expand]CodeRush
[Expand]CodeRush Classic
[Expand]Cross-Platform Core Libraries
[Expand]Tools and Utilities
 End-User Documentation
View this topic on docs.devexpress.com (Learn more)

Specify Data Formatting

This tutorial demonstrates how to specify value formatting for report elements. In particular, it shows how to format numeric values as a currency, apply a percent format and display date/time values in one of the standard forms.

Expanded Format Numeric Values

Locate a control bound to a price field (Unit Price, Extended Price or another one) and switch to the Properties panel. Expand the Actions category and click the Text Format String property's ellipsis button.

The invoked FormatString Editor contains numerous built-in formatting presets grouped by categories. Switch to the Currency category and select a required format pattern to display field values as currency amounts. The editor allows you to see the preview of the selected format in the Preview section.

You can manually create a format if it does not exist in the list by entering the format string in the dedicated editor and clicking Add.

Select a control bound to a field, whose values should be displayed as percents (the Discount field in this example), and invoke the FormatString Editor for it. Choose a format item under the Percent category to apply percent format to this control. In this case, field values are multiplied by 100 and displayed with a percent symbol.

Expanded Format Date-Time Values

Select a date-time field (OrderDate, RequiredDate or ShippedDate), invoke the FormatString Editor and choose one of the standard formats in the DateTime category. For instance, display the date string as the full name of the month followed by the number of the day and a four digit year.

Expanded View the Result

Click the Preview toolbar button to see the result.

Expanded See Also

Is this topic helpful?​​​​​​​