Formatting Display Values with the DisplayFormat Property

The Web Forms mmTextBox and mmLabel classes both have a DisplayFormat property which allows you to format display values on web pages.

The DisplayFormat property uses String.Format() expressions to format the display value (similar to what you use when formatting columns in a Web DataGrid). So, for example, to format the date to MM/dd/yyyy you set the property to:

{0:d}

For more information on formatting strings check out these topics:

Standard DateTime Format Strings Output Examples

Standard Numeric Format Strings Output Examples


© (c) 2026 Oak Leaf Enterprises, Inc., 1996-2026 • Updated: 06/03/05
Comment or report problem with topic