RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
TField.Text Property

Contains the string to display in a data-aware control when the field is in edit mode.

Pascal
property Text: string;
C++
__property AnsiString Text;

Data-aware controls rely on the Text property to provide the editing format for each field. For example, by default the Text property of a currency field omits the thousands separators and currency symbol. 

Text can differ from the DisplayText property if the field uses a different string representation when the value is being edited. To implement two different string representations of a field's value, use the OnGetText event handler. If an OnGetText event handler is assigned, Text is the value returned in the Text parameter of the event handler when the DisplayText parameter is false. If there is no OnGetText event handler, Text is the value of the AsString property. 

 

Copyright(C) 2008 CodeGear(TM). All Rights Reserved.
What do you think about this topic? Send feedback!