Skip to main content

DevExpress v24.2 Update — Your Feedback Matters

Our What's New in v24.2 webpage includes product-specific surveys. Your response to our survey questions will help us measure product satisfaction for features released in this major update and help us refine our plans for our next major release.

Take the survey Not interested

How to: Format Values in the Vertical Grid Using Standard Format Strings

The following example demonstrates how to format values in the VerticalGrid’s rows using standard format strings. These are described in the Format Specifiers topic.

Values in the rowPrice row will be formatted as a currency amount. Values in the rowDeliveryDate row will be represented in the Long Date form.

The image below shows the result.

Format - StandardStrings

using DevExpress.Utils;
// ...
rowPrice.Properties.Format.FormatType = FormatType.Numeric;
rowPrice.Properties.Format.FormatString = "c2";
rowDeliveryDate.Properties.Format.FormatType = FormatType.DateTime;
rowDeliveryDate.Properties.Format.FormatString = "D";