:: Documentation >>

valueToText

Formats the value for display. This method may be used internally by the grid control to produce the cell text from the cell value property.

null

Syntax

var text = format.valueToText(value);

Parameters

value (string/number/date) - cell value

Returns

text string formatted for display

Examples

// create and configure date converter
var date = new AW.Formats.Date;
date.setTextFormat("mmm d, yyyy");

var value = 1084834800000; // May 18, 2004
var text = date.valueToText(value);

Remarks

Derived classes (AW.Formats.Number, AW.Formats.Date) overwrite dataToText() and valueToText() methods according to the pattern specified in the setTextFormat() call.

If the data cannot be parsed - the method returns error text which can be configured with setErrorText() call.

See also

AW.System.Format methods: dataToText, valueToData, setErrorText
Formatting classes: number, string, html, date
Grid cell properties: text, value, data, format

Comments

Documentation:

Recent changes:

2.6.4
2.6.3
2.6.2
2.6.1
2.6.1
2.6.0
2.5.0 - 2.5.6
2.5.6
2.5.0 - 2.5.5
2.5.5