RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
TFieldValuesAdapter Class

TFieldValuesAdapter is an adapter that includes a single field value.

Pascal
TFieldValuesAdapter = class(TAbstractFieldValuesAdapter);
C++
class TFieldValuesAdapter : public TAbstractFieldValuesAdapter;

Use TFieldValuesAdapter to represent a single field value, which is available as a field with the name 'ValueField'. The single field is represented by an adapter field object that is of type TFieldValuesValueField, or one of its descendants. This adapter field object is supplied to the TFieldValuesAdapter constructor. 

The 'ValueField' field can have multiple values, such as when it represents a value in the column of a table. For example, the following server-side script iterates over the values of the 'ValueField' field and adds them to a table:

<table border=1>
<%
   var e = new Enumerator(FieldValuesAdapter1)
   for (; !e.atEnd(); e.moveNext())
   {
%>
  <tr><td><%=e.item().ValueField%></td></tr>
<%
   }
%>
</table>

 

Copyright(C) 2009 Embarcadero Technologies, Inc. All Rights Reserved.
What do you think about this topic? Send feedback!