The requested page is not available for the requested platform. You are viewing the content for Default platform.

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.

RS_FormattingResult-highlight

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.

report-server-table-cell-format-string-property

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.

report-server-format-string-editor-currency

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.

report-server-format-string-editor-percent

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.

report-server-format-string-editor-date-time

View the Result

Click the Preview report-server-web-preview-button toolbar button to see the result.

report-server-data-formatting-result

See Also